Answer the question
In order to leave comments, you need to log in
How to sort out npm run dev issue?
after entering the command npm run dev gives:
npm run dev
> @ dev C:\OSPanel\domains\pgg2.ru
> npm run development
> @ development C:\OSPanel\domains\pgg2.ru
> cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup
/webpack.config.js
98% after emitting SizeLimitsPlugin
ERROR Failed to compile with 1 errors 13:28:33
error in ./resources/js/components/ImageUpload.vue?vue&type=script&lang=js&
Syntax Error: SyntaxError: C:\OSPanel\domains\pgg2.ru\resources\js\components\ImageUpload.vue: Unexpected token, expected "," (56:50)
54 | form.append('image', item);
55 |
> 56 | await axios.post('/image/upload', form{
| ^
57 | onUploadProgress:(itemUpload) => {
58 | this.fileProgress = Math.round( (itemUpload.loaded / itemUpload.total) * 100);
59 | this.fileCurrent = item.name + ' ' + this.fileProgress;
@ ./resources/js/components/ImageUpload.vue?vue&type=script&lang=js& 1:0-187 1:203-206 1:208-392 1:208-392
@ ./resources/js/components/ImageUpload.vue
@ ./resources/js/app.js
@ multi ./resources/js/app.js ./resources/sass/app.scss
Asset Size Chunks Chunk Names
/css/app.css 174 KiB /js/app [emitted] /js/app
/js/app.js 1.4 MiB /js/app [emitted] /js/app
ERROR in ./resources/js/components/ImageUpload.vue?vue&type=script&lang=js& (./node_modules/babel-loader/lib??ref--4-0!./node_modules/
vue-loader/lib??vue-loader-options!./resources/js/components/ImageUpload.vue?vue&type=script&lang=js&)
Module build failed (from ./node_modules/babel-loader/lib/index.js):
SyntaxError: C:\OSPanel\domains\pgg2.ru\resources\js\components\ImageUpload.vue: Unexpected token, expected "," (56:50)
54 | form.append('image', item);
55 |
> 56 | await axios.post('/image/upload', form{
| ^
57 | onUploadProgress:(itemUpload) => {
58 | this.fileProgress = Math.round( (itemUpload.loaded / itemUpload.total) * 100);
59 | this.fileCurrent = item.name + ' ' + this.fileProgress;
at Parser.raise (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:3851:17)
at Parser.unexpected (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5167:16)
at Parser.expect (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5153:28)
at Parser.parseCallExpressionArguments (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6106:14)
at Parser.parseSubscript (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6016:29)
at Parser.parseSubscripts (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5935:19)
at Parser.parseExprSubscripts (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5924:17)
at Parser.parseMaybeUnary (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5894:21)
at Parser.parseAwait (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:7062:26)
at Parser.parseMaybeUnary (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5859:19)
at Parser.parseExprOps (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5781:23)
at Parser.parseMaybeConditional (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5754:23)
at Parser.parseMaybeAssign (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5701:21)
at Parser.parseExpression (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5649:23)
at Parser.parseStatementContent (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:7420:23)
at Parser.parseStatement (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:7291:17)
at Parser.parseBlockOrModuleBlockBody (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:7868:25)
at Parser.parseBlockBody (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:7855:10)
at Parser.parseBlock (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:7839:10)
at Parser.parseFunctionBody (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6909:24)
at Parser.parseFunctionBodyAndFinish (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6879:10)
at Parser.parseMethod (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6835:10)
at Parser.parseObjectMethod (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6751:19)
at Parser.parseObjPropValue (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6793:23)
at Parser.parseObjectMember (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6717:10)
at Parser.parseObj (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6641:25)
at Parser.parseExprAtom (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6274:21)
at Parser.parseExprSubscripts (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5914:23)
at Parser.parseMaybeUnary (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5894:21)
at Parser.parseExprOps (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5781:23)
at Parser.parseMaybeConditional (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5754:23)
at Parser.parseMaybeAssign (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:5701:21)
at Parser.parseObjectProperty (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6768:101)
at Parser.parseObjPropValue (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6793:101)
at Parser.parseObjectMember (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6717:10)
at Parser.parseObj (C:\OSPanel\domains\pgg2.ru\node_modules\@babel\parser\lib\index.js:6641:25)
@ ./resources/js/components/ImageUpload.vue?vue&type=script&lang=js& 1:0-187 1:203-206 1:208-392 1:208-392
@ ./resources/js/components/ImageUpload.vue
@ ./resources/js/app.js
@ multi ./resources/js/app.js ./resources/sass/app.scss
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! @ development: `cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_mo
dules/laravel-mix/setup/webpack.config.js`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the @ development 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\seo16\AppData\Roaming\npm-cache\_logs\2019-04-26T08_28_34_561Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! @ dev: `npm run development`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the @ dev 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\seo16\AppData\Roaming\npm-cache\_logs\2019-04-26T08_28_35_038Z-debug.log
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question