πŸ”  Responsive fontSize based on screen-size of the device in React-Native
Clone or download
Latest commit 4b320c2 Dec 30, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.circleci Update config.yml Dec 7, 2018
images add screenshots Apr 29, 2018
.npmignore add .npmignore Dec 30, 2018
.prettierrc set circleci config file Dec 7, 2018
LICENSE Create LICENSE (#1) Apr 28, 2018
README.md Update README.md (#8) Dec 7, 2018
index.ts rollback test code Dec 7, 2018
package.json add .npmignore Dec 30, 2018

README.md

react-native-responsive-fontsize

PRs Welcome Platform License

This is simple method for responsive font size
Basically it depends on device height

How to install

yarn add react-native-responsive-fontsize
or
npm install react-native-responsive-fontsize --save

How it looks on different device sizes

iPhone SE iPhone X

Usage

import RF from "react-native-responsive-fontsize"

const styles = StyleSheet.create({
  welcome: {
    fontSize: RF(3.5),
    textAlign: "center",
    margin: 10
  },
  instructions: {
    textAlign: "center",
    color: "#333333",
    marginBottom: 5,
    fontSize: RF(2.5)
  }
})