Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Change CSS preprocessors doc for composability
Since there are dupes in `watch-css` we can just run the same command written in the `build-css` npm script, escape the following params with `--` and specify the params for `build-css`.
  • Loading branch information
diagramatics authored Apr 23, 2017
commit f0ee18f7018544037a72087b0d53855935eaa93c
7 changes: 3 additions & 4 deletions packages/react-scripts/template/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ Then in `package.json`, add the following lines to `scripts`:
```diff
"scripts": {
+ "build-css": "node-sass src/ -o src/",
+ "watch-css": "npm run build-css && node-sass src/ -o src/ --watch --recursive",
+ "watch-css": "npm run build-css && npm run build-css -- --watch --recursive",
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test --env=jsdom",
Expand All @@ -455,7 +455,7 @@ Then we can change `start` and `build` scripts to include the CSS preprocessor c
```diff
"scripts": {
"build-css": "node-sass src/ -o src/",
"watch-css": "npm run build-css && node-sass src/ -o src/ --watch --recursive",
"watch-css": "npm run build-css && npm run build-css -- --watch --recursive",
- "start": "react-scripts start",
- "build": "react-scripts build",
+ "start-js": "react-scripts start",
Expand All @@ -482,9 +482,8 @@ And in your scripts:
```diff
"scripts": {
- "build-css": "node-sass src/ -o src/",
- "watch-css": "npm run build-css && node-sass src/ -o src/ --watch --recursive"
+ "build-css": "node-sass-chokidar src/ -o src/",
+ "watch-css": "npm run build-css && node-sass-chokidar src/ -o src/ --watch --recursive"
"watch-css": "npm run build-css && npm run build-css -- --watch --recursive"
}
```

Expand Down