Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

mvnobrega's avatar

Error installing Vuejs

I'm trying to install vuejs + Vite in laravel 10 according to what is suggested on several sites, which would be the following order:

composer create-project laravel/laravel laravel10-vue3

npm install

npm install vue@next vue-loader@next

npm i @vitejs/plugin-vue

However, when I run "npm install vue@next vue-loader@next", I get this error:

npm ERR! code ETARGET
npm ERR! notarget No matching version found for vue@next.
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\marqu\AppData\Local\npm-cache\_logs24-01-08T00_52_37_537Z-debug-0.log

Can anyone help me resolve this?

0 likes
5 replies
MaverickChan's avatar

you don't need vue-loader, just install vue and you will be fine

mvnobrega's avatar

@Snapey

I just tried "npm install vue@next" and the same error occurs. What can it be ?

louie4's avatar

Delete node_modules and package-lock.json

Run the following command npm cache clean --force

The crucial step is to update your package.json file. Verify for any new versions of vite and laravel-vite-plugin and update their entries accordingly.

    "devDependencies": {
        "laravel-vite-plugin": "^1.0.1",
        "vite": "^5.0.11"
    },

Run the following commands

npm install
npm install vue@latest vue-loader@latest
npm install @vitejs/plugin-vue
2 likes
enoch91's avatar

@mvnobrega Instead of @next, try installing a specific version of Vue.

npm install [email protected] vue-loader@next

Replace 3.2.20 with the version you want to install. You can check the available versions on the Vue.js releases here

MeisamTj's avatar

Or you can use starter-kit such as Breeze. It also installs inertia.js and tailwind css. Good luck!

Please or to participate in this conversation.