DimiMikadze / create-react-library

React NPM library starter kit based on Facebook's create react app
MIT License
602 stars 60 forks source link

node-sass-chokidar #22

Closed diegoalmesp closed 6 years ago

diegoalmesp commented 6 years ago

Hi! great work! exactly what I was looking for.

I'm a little bit lost on how to have node-sass-chokidar working. I want to use a modified bootstrap version for my library, with sass.

Could you please help me with this?

Thanks and thanks for the contribution!

Diego

diegoalmesp commented 6 years ago

Nevermind!!! I thought that it wasn't working because I was importing the scss file into App.js while I just needed to import the generated css. Thanks!

Note.: I used the official create-react-app guide in the docs, and in package.json now I have this:

"scripts": {
    "start-js": "node scripts/start.js",
    "build-js": "node scripts/build.js",
    "demo": "node scripts/demo.js",
    "test": "node scripts/test.js --env=jsdom",
    "build-css": "node-sass-chokidar src/lib/ -o src/lib/",
    "watch-css": "npm run build-css && node-sass-chokidar src/lib/ -o src/lib/ --watch --recursive",
    "start": "npm-run-all -p watch-css start-js",
    "build": "npm run build-css && build-js"
  },