Error running "npm run dv"

Asked

Viewed 132 times

0

npm run dev

@ dev /var/www/Upevent node node_modules/cross-env/bin/cross-env.js NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js

module.js:549

throw err;
^

Error: Cannot find module '/var/www/Upevent/node_modules/cross-env/bin/cross-env.js' At function.Module. _resolveFilename (module.js:547:15) At function.Module. _load (module.js:474:25) At Function.Module.runMain (module.js:693:10) at startup (bootstrap_node.js:188:16) at bootstrap_node.js:609:3 npm ERR! code ELIFECYCLE npm ERR! Errno 1 npm ERR! @dev: node node_modules/cross-env/bin/cross-env.js NODE_ENV=development 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 @devscript. 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!
/home/imacruz/. npm/_logs/2018-04-17T13_58_27_867Z-debug.log

  • Post the contents of your webpack.conf. What’s more, the message says you’re trying to get a module not found, so make sure it’s installed.

  • I already deleted the entire node_modules folder and reinstalled but it won’t, I’m not finding this file webpack.conf wouldn’t be webpack.mix.js ?

  • Soon, you understood which file I was talking about, because, yes it is this.

  • let mix = require('laravel-mix');

/*
 |--------------------------------------------------------------------------
 | Mix Asset Management
 |--------------------------------------------------------------------------
 |
 | Mix provides a clean, Fluent API for Defining some Webpack build Steps | for your Laravel application. By default, we are compiling the Sass | file for the application as well as bundling up all the JS files. | */ mix.js('Resources/Assets/js/app.js', 'public/js') . Sass('Resources/Assets/Sass/app.scss', 'public/css');

  • Edit your question and put the code there. If you don’t know how to do it, I recommend you take the tour of how the site works: https://answall.com/tour

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.