Okay
  Public Ticket #1810089
error installation vue
Open

Comments

  • pspp started the conversation

    hello I followed the steps for the installation, before running npm run dev I can see the test of the project but without images; my project has the name of vjfact, I established the; mix.setResourceRoot ('/ vjfact / public /'). But when installing vue, at 95% the following error occurs:

    ERROR in ./node_modules/vue-loader/lib/template-compiler?{"id":"data-v-5f745706","hasScoped":true,"buble":{"transforms":{}}}!./node_modules/vue-loader/lib/selector.js?type=template&index=0!./resources/assets/components/widgets/chat_component/chat-large.vue
    Module not found: Error: Can't resolve 'img/pages/chat_background2.jpg' in 'C:\laragon\www\vjfact\resources\assets\components\widgets\chat_component'
     @ ./node_modules/vue-loader/lib/template-compiler?{"id":"data-v-5f745706","hasScoped":true,"buble":{"transforms":{}}}!./node_modules/vue-loader/lib/selector.js?type=template&index=0!./resources/assets/components/widgets/chat_component/chat-large.vue 139:27-68 142:22-63 147:36-77
     @ ./resources/assets/components/widgets/chat_component/chat-large.vue
     @ ./node_modules/babel-loader/lib?{"cacheDirectory":true,"presets":[["env",{"modules":false,"targets":{"browsers":["> 2%"],"uglify":true}}]],"plugins":["transform-object-rest-spread",["transform-runtime",{"polyfill":false,"helpers":false}]]}!./node_modules/vue-loader/lib/selector.js?type=script&index=0!./resources/assets/components/pages/chat.vue
     @ ./resources/assets/components/pages/chat.vue
     @ ./resources/assets/router/layout.js
     @ ./resources/assets/router/routes.js
     @ ./resources/assets/router/index.js
     @ ./resources/assets/main.js
     @ multi ./resources/assets/main.js

    ERROR in ./node_modules/css-loader!./node_modules/vue-loader/lib/style-compiler?{"vue":true,"id":"data-v-5f745706","scoped":true,"hasInlineConfig":true}!./node_modules/sass-loader/lib/loader.js!./node_modules/vue-loader/lib/selector.js?type=styles&index=0!./resources/assets/components/widgets/chat_component/chat-large.vue
    Module not found: Error: Can't resolve 'img/pages/chat_background2.jpg' in 'C:\laragon\www\vjfact\resources\assets\components\widgets\chat_component'
     @ ./node_modules/css-loader!./node_modules/vue-loader/lib/style-compiler?{"vue":true,"id":"data-v-5f745706","scoped":true,"hasInlineConfig":true}!./node_modules/sass-loader/lib/loader.js!./node_modules/vue-loader/lib/selector.js?type=styles&index=0!./resources/assets/components/widgets/chat_component/chat-large.vue 7:1086-1127
     @ ./node_modules/vue-style-loader!./node_modules/css-loader!./node_modules/vue-loader/lib/style-compiler?{"vue":true,"id":"data-v-5f745706","scoped":true,"hasInlineConfig":true}!./node_modules/sass-loader/lib/loader.js!./node_modules/vue-loader/lib/selector.js?type=styles&index=0!./resources/assets/components/widgets/chat_component/chat-large.vue
     @ ./resources/assets/components/widgets/chat_component/chat-large.vue
     @ ./node_modules/babel-loader/lib?{"cacheDirectory":true,"presets":[["env",{"modules":false,"targets":{"browsers":["> 2%"],"uglify":true}}]],"plugins":["transform-object-rest-spread",["transform-runtime",{"polyfill":false,"helpers":false}]]}!./node_modules/vue-loader/lib/selector.js?type=script&index=0!./resources/assets/components/pages/chat.vue
     @ ./resources/assets/components/pages/chat.vue
     @ ./resources/assets/router/layout.js
     @ ./resources/assets/router/routes.js
     @ ./resources/assets/router/index.js
     @ ./resources/assets/main.js
     @ multi ./resources/assets/main.js
    npm ERR! code ELIFECYCLE
    npm ERR! errno 2
    npm ERR! vuejs-admin@1.0.0 development: `cross-env 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 2
    npm ERR!
    npm ERR! Failed at the vuejs-admin@1.0.0 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\user\AppData\Roaming\npm-cache\_logs\2018-12-06T02_39_14_236Z-debug.log
    npm ERR! code ELIFECYCLE
    npm ERR! errno 2
    npm ERR! vuejs-admin@1.0.0 dev: `npm run development`
    npm ERR! Exit status 2
    npm ERR!
    npm ERR! Failed at the vuejs-admin@1.0.0 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\user\AppData\Roaming\npm-cache\_logs\2018-12-06T02_39_14_266Z-debug.log

    C:\laragon\www\vjfact

    Attached files:  img1.JPG
      img2.JPG

  •  92
    Jyostna replied

    Hello,

    Please check the image by the name "chat_background2.jpg" exists in your folder structure 
    'resources/assets/assets/img/pages'

    Check the extension of the image is jpg (chat_background2.jpg) in your folder structure.
    If not change the extension of the image as jpg.

    And run the command 
    npm run dev

    Thanks,

  • pspp replied

    gracias !!!, funcionó.

  •  92
    Jyostna replied

    Hello,

    Glad to hear.

    Thanks,

  • pspp replied

    Hello, I am sorry, "npm run dev" works fine without errors, but the images and icons do not load on the front-end, did I forget anything?

    Attached files:  img1.JPG

  •  92
    Jyostna replied

    Hello, 


    In the webpack.mix.js file,can you please set the resource root path as below

    mix.setResourceRoot('/')

    and run the command "npm run dev" 



    Thanks,