rn-responsive-screen
v1.1.9
Published
Small Package used for responsiveness in your react native app
Downloads
295
Maintainers
Readme
About The Project
Responsive app design is an approach to app design that makes its screen render well on a variety of devices and window or screen sizes
Responsive design can help you solve a lot of problems for your app. It will make your app user -friendly, improve the way it looks on devices with both large and small screens, and increase the amount of time that visitors spend on your app.
Built With
Getting Started
Installation
- npm
npm install --save rn-responsive-screen
- yarn
yarn add rn-responsive-screen
Usage
import { StatusBar } from "expo-status-bar";
import React from "react";
import { StyleSheet, Text, View } from "react-native";
import { widthToDp, heightToDp } from "rn-responsive-screen";
export default function App() {
return (
<View style={styles.container}>
<Text style={styles.test}>
Open up App.js to start working on your app!
</Text>
<StatusBar style="auto" />
</View>
);
}
const styles = StyleSheet.create({
test: {
marginTop: heightToDp("10%"),
width: widthToDp("30%"),
},
});
Contributing
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch
- Commit your Changes
- Push to the Branch
- Open a Pull Request
License
Distributed under the MIT License. See LICENSE
for more information.
Contact
Your Name - @suhailkakar - [email protected]
Website - suhailkakar.com
Project Link: https://www.npmjs.com/package/rn-responsive-screen