Report a bug
I get the following error message when running npm run prebuild:prod && npm run build:prod
67% 1154/1205 build modulesModuleBuildError: Module build failed: ModuleBuildError: Module build failed:
@import "~Ionicons/scss/ionicons";
^
File to import not found or unreadable: ~Ionicons/scss/ionicons
Parent style sheet: /home/felipe/storedash-ui/src/app/theme/sass/_ionicons.scss
in /home/felipe/storedash-ui/src/app/theme/sass/_ionicons.scss (line 3, column 1)
at DependenciesBlock.onModuleBuildFailed (/home/felipe/storedash-ui/node_modules/webpack-core/lib/NormalModuleMixin.js:315:19)
at nextLoader (/home/felipe/storedash-ui/node_modules/webpack-core/lib/NormalModuleMixin.js:270:31)
at /home/felipe/storedash-ui/node_modules/webpack-core/lib/NormalModuleMixin.js:292:15
at context.callback (/home/felipe/storedash-ui/node_modules/webpack-core/lib/NormalModuleMixin.js:148:14)
at Object.onRender (/home/felipe/storedash-ui/node_modules/sass-loader/index.js:272:13)
at /home/felipe/storedash-ui/node_modules/async/lib/async.js:906:35
at _arrayEach (/home/felipe/storedash-ui/node_modules/async/lib/async.js:85:13)
at Object.<anonymous> (/home/felipe/storedash-ui/node_modules/async/lib/async.js:898:17)
at Object.callback (/home/felipe/storedash-ui/node_modules/async/lib/async.js:44:16)
at options.error (/home/felipe/storedash-ui/node_modules/node-sass/lib/index.js:275:32)
at DependenciesBlock.onModuleBuildFailed (/home/felipe/storedash-ui/node_modules/webpack-core/lib/NormalModuleMixin.js:315:19)
at DependenciesBlock.<anonymous> (/home/felipe/storedash-ui/node_modules/webpack-core/lib/NormalModuleMixin.js:228:39)
at context.callback (/home/felipe/storedash-ui/node_modules/webpack-core/lib/NormalModuleMixin.js:148:14)
at Object.<anonymous> (/home/felipe/storedash-ui/node_modules/extract-text-webpack-plugin/loader.js:82:20)
at Compiler.<anonymous> (/home/felipe/storedash-ui/node_modules/webpack/lib/Compiler.js:204:18)
at Compiler.<anonymous> (/home/felipe/storedash-ui/node_modules/webpack/lib/Compiler.js:395:18)
at /home/felipe/storedash-ui/node_modules/tapable/lib/Tapable.js:99:11
at Compilation.<anonymous> (/home/felipe/storedash-ui/node_modules/webpack/lib/Compilation.js:433:11)
at errorAndCallback (/home/felipe/storedash-ui/node_modules/webpack/lib/Compilation.js:340:3)
at Compilation.<anonymous> (/home/felipe/storedash-ui/node_modules/webpack/lib/Compilation.js:400:12)
at /home/felipe/storedash-ui/node_modules/webpack/lib/Compilation.js:123:4
at Array.forEach (native)
at callback (/home/felipe/storedash-ui/node_modules/webpack/lib/Compilation.js:122:12)
at Compilation.<anonymous> (/home/felipe/storedash-ui/node_modules/webpack/lib/Compilation.js:137:11)
at DependenciesBlock.<anonymous> (/home/felipe/storedash-ui/node_modules/webpack/lib/NormalModule.js:85:18)
at DependenciesBlock.onModuleBuildFailed (/home/felipe/storedash-ui/node_modules/webpack-core/lib/NormalModuleMixin.js:315:10)
at nextLoader (/home/felipe/storedash-ui/node_modules/webpack-core/lib/NormalModuleMixin.js:270:31)
at /home/felipe/storedash-ui/node_modules/webpack-core/lib/NormalModuleMixin.js:292:15
at context.callback (/home/felipe/storedash-ui/node_modules/webpack-core/lib/NormalModuleMixin.js:148:14)
at Object.onRender (/home/felipe/storedash-ui/node_modules/sass-loader/index.js:272:13)
at /home/felipe/storedash-ui/node_modules/async/lib/async.js:906:35
at _arrayEach (/home/felipe/storedash-ui/node_modules/async/lib/async.js:85:13)
at Object.<anonymous> (/home/felipe/storedash-ui/node_modules/async/lib/async.js:898:17)
at Object.callback (/home/felipe/storedash-ui/node_modules/async/lib/async.js:44:16)
at options.error (/home/felipe/storedash-ui/node_modules/node-sass/lib/index.js:275:32)
npm ERR! Linux 4.2.0-27-generic
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "run" "build:prod"
npm ERR! node v5.10.0
npm ERR! npm v3.8.3
npm ERR! code ELIFECYCLE
npm ERR! [email protected] build:prod: `webpack --config config/webpack.prod.js --progress --profile --colors --display-error-details --display-cached --bail`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] build:prod script 'webpack --config config/webpack.prod.js --progress --profile --colors --display-error-details --display-cached --bail'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the ng2-admin package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! webpack --config config/webpack.prod.js --progress --profile --colors --display-error-details --display-cached --bail
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs ng2-admin
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls ng2-admin
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/felipe/storedash-ui/npm-debug.log
i'm facing the same issue with centos 7.
in windows the app is build and serving fine.
any idea on solving this issue.
thanks
@punith-s make sure you have bower installed globally and run the bower install command.
An additional remark, I try to upgrade the project to the latest package version and got the same error when I use a newer version of the ionicons, after downgrading this package to the orginial package version the error disapeared
PS when I try to run the bower install it complain that it can not find a bower json config file, is there not more you have to do except running bower install?
The directory structure of ionicons changed with the new release. You need to edit all the imports to have the dist/ directory e.g ~ionicons/dist/fonts
Most helpful comment
The directory structure of ionicons changed with the new release. You need to edit all the imports to have the dist/ directory e.g ~ionicons/dist/fonts