How to use CSS in ReactNative

Can I use CSS to style my ReactNative . Currently I can use StyleSheet like this:

var styles = React.StyleSheet.create({
 autocomplete: {
   backgroundColor: '#FFF',
   zIndex: 5,


I want to use CSS instead like in ReactJs


source to share

3 answers

What does pure css mean ?

Have a look at styled-components , the project is under active development.

This allows you to build your reactive components using css.



I had the same problem and solved it using this component. I see it is not being developed anymore, but it works great for me.

It basically takes your CSS files and generates some StyleSheet components from them that you can easily integrate into your responsive application.



Try this library:

You can style components with CSS and inline SASS support.



All Articles