{"id":27870802,"url":"https://github.com/newbiebr/react-native-normalize","last_synced_at":"2025-05-04T23:26:50.454Z","repository":{"id":35041196,"uuid":"199434979","full_name":"NewBieBR/react-native-normalize","owner":"NewBieBR","description":"Small and simple package that helps make your React Native app responsive easily","archived":false,"fork":false,"pushed_at":"2023-01-04T05:49:45.000Z","size":3168,"stargazers_count":152,"open_issues_count":21,"forks_count":12,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-25T15:22:47.301Z","etag":null,"topics":["normalize","react-native","responsive","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/NewBieBR.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-07-29T10:53:09.000Z","updated_at":"2025-03-25T11:25:43.000Z","dependencies_parsed_at":"2023-01-15T12:45:35.003Z","dependency_job_id":null,"html_url":"https://github.com/NewBieBR/react-native-normalize","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/NewBieBR%2Freact-native-normalize","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NewBieBR%2Freact-native-normalize/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NewBieBR%2Freact-native-normalize/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NewBieBR%2Freact-native-normalize/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/NewBieBR","download_url":"https://codeload.github.com/NewBieBR/react-native-normalize/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252413054,"owners_count":21743813,"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":["normalize","react-native","responsive","typescript"],"created_at":"2025-05-04T23:26:49.660Z","updated_at":"2025-05-04T23:26:50.434Z","avatar_url":"https://github.com/NewBieBR.png","language":"TypeScript","readme":"[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)\n[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](./CONTRIBUTING.md)\n[![npm version](https://badge.fury.io/js/react-native-normalize.svg)](https://badge.fury.io/js/react-native-normalize)\n\n### Without `normalize`\n\u003cimg src=\"https://i.imgur.com/bLbnjsC.jpg\" width=\"600\"/\u003e\n\n### With `normalize`\n\u003cimg src=\"https://i.imgur.com/4IqqAR2.jpg\" width=\"600\"/\u003e\n\n# React Native Normalize\n\n**react-native-normalize** is a small and simple package that helps make your React Native app responsive easily.\n\nIt comes with a function `normalize` that will adapt a value depending on the screen's width or height so you can use it for `width, height, top, bottom, fontSize, borderRadius,...`\n\n\n```javascript\n// on iPhone 8\nnormalize(100)          // = 100\nnormalize(50, 'height') // = 50\n\n// on iPhone 5s\nnormalize(100)          // = 86\nnormalize(50, 'height') // = 43\n\n// on iPhoneXs Max\nnormalize(100)          // = 110\nnormalize(50, 'height') // = 67\n```\n\n## Quick example\n\n```JSX\nimport React from 'react';\nimport { Text, View, StyleSheet } from 'react-native';\nimport normalize from 'react-native-normalize';\n\nexport default class App extends React.Component {\n  render() {\n    return (\n      \u003cView style={styles.container}\u003e\n        \u003cView style={styles.box}\u003e\n          \u003cText style={styles.text}\u003eReact Native Normalize\u003c/Text\u003e\n        \u003c/View\u003e\n      \u003c/View\u003e\n    );\n  }\n}\n\nconst styles = StyleSheet.create({\n  container: {\n    flex: 1,\n  },\n  box: {\n    alignItems: 'center',\n    justifyContent: 'center',\n    top: normalize(180, 'height'),\n    left: normalize(40),\n    width: normalize(300),\n    height: normalize(300),\n    borderRadius: normalize(150),\n    backgroundColor: '#009fcd',\n  },\n  text: {\n    fontSize: normalize(60),\n    color: 'white',\n  },\n});\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnewbiebr%2Freact-native-normalize","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnewbiebr%2Freact-native-normalize","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnewbiebr%2Freact-native-normalize/lists"}