{"id":4273,"url":"https://github.com/Shuangzuan/react-native-square-view","last_synced_at":"2025-08-04T01:31:44.758Z","repository":{"id":33327269,"uuid":"36972024","full_name":"Shuangzuan/react-native-square-view","owner":"Shuangzuan","description":"A square view component for react native.","archived":false,"fork":false,"pushed_at":"2017-09-19T14:20:58.000Z","size":180,"stargazers_count":24,"open_issues_count":4,"forks_count":5,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-04-26T02:35:38.921Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Shuangzuan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-06-06T07:47:06.000Z","updated_at":"2023-03-09T02:24:32.000Z","dependencies_parsed_at":"2022-08-29T14:41:35.815Z","dependency_job_id":null,"html_url":"https://github.com/Shuangzuan/react-native-square-view","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Shuangzuan%2Freact-native-square-view","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Shuangzuan%2Freact-native-square-view/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Shuangzuan%2Freact-native-square-view/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Shuangzuan%2Freact-native-square-view/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Shuangzuan","download_url":"https://codeload.github.com/Shuangzuan/react-native-square-view/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228582487,"owners_count":17940587,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-01-05T20:17:06.531Z","updated_at":"2024-12-07T08:30:25.957Z","avatar_url":"https://github.com/Shuangzuan.png","language":null,"funding_links":[],"categories":["Components","Others"],"sub_categories":["UI"],"readme":"# react-native-square-view\nA square view component for react native.\n\n## Screen Shot\n\n![Screen Shot](screen-shot.png)\n\n## Installation\n\n1. Run `npm install react-native-square-view --save` in your project directory.\n2. Add `var SquareView = require('react-native-square-view');` to your code.\n\n## Usage\n\n```javascript\n'use strict';\n\nvar React = require('react-native');\nvar {\n  AppRegistry,\n  StyleSheet,\n  Text,\n  View,\n  ScrollView\n} = React;\nvar SquareView = require('react-native-square-view');\n\nvar SquareViewDemo = React.createClass({\n  render: function() {\n    return (\n      \u003cScrollView style={styles.container} contentInset={{top: 20}}\u003e\n        \u003cText\u003eParent w {'\u003e'} h and direction is column:\u003c/Text\u003e\n        \u003cView style={{width: 200, height: 100, backgroundColor: 'orange'}}\u003e\n          \u003cSquareView style={{flex: 1, margin: 8, alignItems: 'center', justifyContent: 'center'}}\u003e\n            \u003cText\u003eA\u003c/Text\u003e\n          \u003c/SquareView\u003e\n          \u003cSquareView style={{flex: 1, margin: 8, alignItems: 'center', justifyContent: 'center'}}\u003e\n            \u003cText\u003eA\u003c/Text\u003e\n          \u003c/SquareView\u003e\n        \u003c/View\u003e\n\n        \u003cText\u003eParent w {'\u003e'} h and direction is row:\u003c/Text\u003e\n        \u003cView style={{width: 200, height: 100, backgroundColor: 'purple', flexDirection: 'row'}}\u003e\n          \u003cSquareView style={{flex: 1, margin: 8, alignItems: 'center', justifyContent: 'center'}}\u003e\n            \u003cText\u003eB\u003c/Text\u003e\n          \u003c/SquareView\u003e\n          \u003cSquareView style={{flex: 1, margin: 8, alignItems: 'center', justifyContent: 'center'}}\u003e\n            \u003cText\u003eB\u003c/Text\u003e\n          \u003c/SquareView\u003e\n          \u003cSquareView style={{flex: 1, margin: 8, alignItems: 'center', justifyContent: 'center'}}\u003e\n            \u003cText\u003eB\u003c/Text\u003e\n          \u003c/SquareView\u003e\n        \u003c/View\u003e\n\n        \u003cText\u003eParent w {'\u003c'} h and direction is column:\u003c/Text\u003e\n        \u003cView style={{width: 100, height: 200, backgroundColor: 'orange'}}\u003e\n          \u003cSquareView style={{flex: 1, margin: 8, alignItems: 'center', justifyContent: 'center'}}\u003e\n            \u003cText\u003eC\u003c/Text\u003e\n          \u003c/SquareView\u003e\n          \u003cSquareView style={{flex: 1, margin: 8, alignItems: 'center', justifyContent: 'center'}}\u003e\n            \u003cText\u003eC\u003c/Text\u003e\n          \u003c/SquareView\u003e\n        \u003c/View\u003e\n\n        \u003cText\u003eParent w {'\u003c'} h and direction is row:\u003c/Text\u003e\n        \u003cView style={{width: 100, height: 200, backgroundColor: 'purple', flexDirection: 'row'}}\u003e\n          \u003cSquareView style={{flex: 1, margin: 8, alignItems: 'center', justifyContent: 'center'}}\u003e\n            \u003cText\u003eD\u003c/Text\u003e\n          \u003c/SquareView\u003e\n          \u003cSquareView style={{flex: 1, margin: 8, alignItems: 'center', justifyContent: 'center'}}\u003e\n            \u003cText\u003eD\u003c/Text\u003e\n          \u003c/SquareView\u003e\n        \u003c/View\u003e\n\n      \u003c/ScrollView\u003e\n    );\n  }\n});\n\nvar styles = StyleSheet.create({\n  container: {\n    flex: 1\n  }\n});\n\nAppRegistry.registerComponent('SquareViewDemo', () =\u003e SquareViewDemo);\n```\n\n---\n\n## License\n\nAvailable under the MIT license. See the LICENSE file for more informatiion.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FShuangzuan%2Freact-native-square-view","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FShuangzuan%2Freact-native-square-view","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FShuangzuan%2Freact-native-square-view/lists"}