Use SASS in React

How to style a React application with SASS

When you use to build a React applicationcreate-react-app, In terms of style, you have many options to use.

Of course, if you don’t usecreate-react-app, You have all the options in the world, but we only limit the discussion tocreate-react-appOptions provided.

You can use the style attribute or CSS module to start using common classes and CSS files for style settings.

SASS/SCSS is a very popular option, and many developers like it very much.

You can use it from the ground up without any configurationcreate-react-app 2.

You only need one.sassor.scssFile, and then import it into the component:

import './styles.scss'

You canhttps://codesandbox.io/s/18qq31rp3.