我正在嘗試從https://github.com/railsadminteam/rails_admin安裝rails_admin
在最后一步
它給了我這個錯誤:
append config/initializers/assets.rb
- Add scripts to package.json
You need to merge "scripts": {
"build:css": "sass ./app/assets/stylesheets/rails_admin.scss:./app/assets/builds/rails_admin.css --no-source-map --load-path=node_modules"
} into the existing scripts in your package.json.
Taking 'build:css' as an example, if you're already have application.sass.css for the sass build, the resulting script would look like:
sass ./app/assets/stylesheets/application.sass.scss:./app/assets/builds/application.css ./app/assets/stylesheets/rails_admin.scss:./app/assets/builds/rails_admin.css --no-source-map --load-path=node_modules
已嘗試將package.json更新為:
{
"name": "app",
"private": true,
"dependencies": {
"sass": "^1.63.4"
},
"scripts": {
"build:css": "sass ./app/assets/stylesheets/application.sass.scss:./app/assets/builds/application.css --no-source-map --load-path=node_modules sass ./app/assets/stylesheets/rails_admin.scss:./app/assets/builds/rails_admin.css --no-source-map --load-path=node_modules"
}
}
并運行rails g rails_admin:install 再次,但仍然是同樣的錯誤。
上一篇vue中gutter跳轉
下一篇c 構造 json數組