加载css库时节点sass chokidar问题@import CSS

时间:2019-01-09 05:10:20

标签: reactjs node-sass node-sass-chokidar

错误:找不到导入文件或不可读。

最近发生反应的情况

index.scss
@import '~bulma/bulma'

“反应”:“ ^ 16.7.0”, “ node-sass-chokidar”:“ ^ 1.3.4”,

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


  "status": 1,
  "file": "/Users/marcelo/Dropbox/Projetos/IRMEI/app-mobile/src/index.scss",
  "line": 1,
  "column": 1,
  "message": "File to import not found or unreadable: ~bulma/bulma.",
  "formatted": "Error: File to import not found or unreadable: ~bulma/bulma.\n        on line 1 of src/index.scss\n>> @import \"~bulma/bulma\";\n\n   ^\n"

0 个答案:

没有答案