looking for some solutions? You are welcome.

SOLVED: Npm run production Missed semicolon error

ekor:

When I run npm run dev it compiles everything with no error but when I try to run npm run production I get this error:

cross-env NODE_ENV=production node_modules/webpack/bin/webpack.js - 
-progress --hide-modules --config=node_modules/laravel- 
mix/setup/webpack.config.js

92% chunk asset optimization 
OptimizeCssAssetsWebpackPluginCssSyntaxError: C:\css\themes\default- 
theme.css:3:19: Missed semicolon
at Input.error 
(C:\Users\me\projects\blog\node_modules\postcss\lib\input.js:130:16)
at Parser.checkMissedSemicolon 
(C:\Users\me\projects\blog\node_modules\postcss\lib\parser.js:603:22)
../
(C:\Users\me\projects\blog\node_modules\extract-text-webpack- 
plugin\dist\index.js:330:9)
at _err1 (eval at create 
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @ production: `cross-env NODE_ENV=production 
node_modules/webpack/bin/webpack.js --progress --hide-modules -- 
config=node_modules/laravel-mix/setup/webpack.config.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @ production script.
npm ERR! This is probably not a problem with npm. There is likely 
additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\me\AppData\Roaming\npm-cache\_logs\2019-03- 
08T05_29_19_030Z-debug.log

Heres my css file

 var map = {  
 "./ar": "./node_modules/moment/locale/ar.js",      
  //list of locale files generated by npm run dev
 "./zh-tw.js": "./node_modules/moment/locale/zh-tw.js"
 };


 function webpackContext(req) {
  var id = webpackContextResolve(req);
   return __webpack_require__(id);
  }
 function webpackContextResolve(req) {
 if(!__webpack_require__.o(map, req)) {
    var e = new Error("Cannot find module '" + req + "'");
    e.code = 'MODULE_NOT_FOUND';
    throw e;
 }
 return map[req];
 }
 webpackContext.keys = function webpackContextKeys() {
 return Object.keys(map);
 };
 webpackContext.resolve = webpackContextResolve;
 module.exports = webpackContext;
 webpackContext.id = "./node_modules/moment/locale sync recursive 
 ^\\.\\/.*$";

I've tried to install sass-lint using npm i sass-lint but it didn't help.



Posted in S.E.F
via StackOverflow & StackExchange Atomic Web Robots
Share:

No comments:

Recent