Integrate Sass & React (create-react-app)

Bootstrapping your app with create-react-app? Super-charge it with Sass to make theming a cinch. Bonus — includes Foundation integration too!

Often I bootstrap my React projects with create-react-app. Just about every-time, I find myself Googling how to integrate Sass (scss). To save time, I’ve followed the advice of Sara Soueidan’s Just write. and jotted it down as reference. Bonus — includes Foundation integration as well!

  1. Install a starter app: $ npx create-react-app [app name]
  2. Eject the build scripts: $ npm run eject
  3. Install & configure Sass loaders: $ npm i -D sass-loader node-sass
  4. Optional — Install & configure Foundation: $ npm i -D foundation-sites

Continue reading “Integrate Sass & React (create-react-app)”