Using Sass/Scss with React App (create-react-app)

1 min read · Apr 12, 2018

There are multiple ways to integrate sass with react app generated by create-react-app but I think this is the the simplest one which I am going to write now. Steps are simple

Folder Structure node_modules/ package.json public/ index.html favicon.ico src/ App.js App.test.js index.js styles/ /components main.scss


- yarn add -D react-app-rewired - yarn add -D react-app-rewire-sass-modules - yarn add -D sass-loader - yarn add -D node-sass
{ "start": "react-scripts start", "build": "react-scripts build" } to { "start": "react-app-rewired start", "build": "react-app-rewired build" }
const rewireSass = require('react-app-rewire-sass-modules'); module.exports = function override(config, env) { config = rewireSass(config, env); return config; };



Credit: SCSS styles/src is taken from here