Closed atipico closed 3 years ago
Need more information. I cannot reproduce this off of a fresh install with @vue/cli@4.1.1
I hit this error just now. i'm using v4.1.1, too. my goal today was to augment an existing vue app that uses vues-orm-localforage. I called vue add Vuetify
in the project folder. I will try again. tell me what other intel you might need from me.
failed again. here's the console spew: mcorn@DESKTOP-55SQIHT MINGW64 ~/Documents/GitHub/vue/vuex-orm-localforage-exemples-master (master) $ vue add vuetify WARN There are uncommited changes in the current repository, it's recommended to commit or stash them first. ? Still proceed? Yes
�📦 Installing vue-cli-plugin-vuetify...
yarn add v1.21.1 [1/4] Resolving packages... [2/4] Fetching packages... info fsevents@1.2.9: The platform "win32" is incompatible with this module. info "fsevents@1.2.9" is an optional dependency and failed compatibility check. Excluding it from installation. [3/4] Linking dependencies... [4/4] Building fresh packages... success Saved 1 new dependency. info Direct dependencies └─ vue-cli-plugin-vuetify@2.0.5 info All dependencies └─ vue-cli-plugin-vuetify@2.0.5 Done in 9.99s. ✔ Successfully installed plugin: vue-cli-plugin-vuetify
? Choose a preset: Default (recommended)
�🚀 Invoking generator for vue-cli-plugin-vuetify...
ERROR Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists.
Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists.
at Collection.get (C:\Users\mcorn\AppData\Roaming\npm\node_modules\@vue\cli\node_modules\jscodeshift\src\Collection.js:215:13)
at injectOptions (C:\Users\mcorn\AppData\Roaming\npm\node_modules\@vue\cli\lib\util\codemods\injectOptions.js:15:6)
at newTransform (C:\Users\mcorn\AppData\Roaming\npm\node_modules\@vue\cli\node_modules\vue-jscodeshift-adapter\src\jscodeshift-mode.js:9:14)
at runCodemod (C:\Users\mcorn\AppData\Roaming\npm\node_modules\@vue\cli\lib\util\runCodemod.js:29:26)
at Object.keys.forEach.file (C:\Users\mcorn\AppData\Roaming\npm\node_modules\@vue\cli\lib\Generator.js:283:23)
at Array.forEach (
$
here is the new line in package.json: "vue-cli-plugin-vuetify": "^2.0.5",
and here is the new content in yarn.lock: "@babel/code-frame@^7.8.3": version "7.8.3" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.8.3.tgz#33e25903d7481181534e12ec0a25f16b6fcf419e" integrity sha512-a9gxpmdXtZEInkCSHUJDLHZVBgb1QS0jhss4cPP93EW7s+uC5bikET2twEF3KV+7rDblJcmNvTR7VJejqd2C2g== dependencies: "@babel/highlight" "^7.8.3"
currently experiencing this
Solved my issue by
new Vue({options})
on the entrypoint file, which is specified on the "main" key at package.json.someone help me with this ?
@paolog22 I can confirm that this issue is probably caused by modifying the entrypoint file or by deleting the public/index.html
file before running the command. At least my issue was solved when recreating the original files and running the command again, like @flaviotsales wrote.
I got the same error in my environment trying vue 3.0 with vue-next.
In my case, I was able to trick the CLI by writing new Vue(...)
in main.ts
to trick the CLI.
However, this is not a fundamental solution, as this does not make vuetify work.
my environment
@vue/cli 4.4.6
vue 3.0.0-beta.18
main.ts
createApp(App)
.use(router)
.use(store)
.mount("#app");
// I don't use it by default.
new Vue({
router,
store,
vuetify,
render: h => h(App)
}).$mount("#app");
Similar issue. I had an existing vue.js project. I used vue add typescript to add typescript support. I then used vue add vuetify With these options... Installing vue-cli-plugin-vuetify...
58 packages are looking for funding
run npm fund
for details
found 1069 low severity vulnerabilities
run npm audit fix
to fix them, or npm audit
for details
✔ Successfully installed plugin: vue-cli-plugin-vuetify
? Choose a preset: Configure (advanced) ? Use a pre-made template? (will replace App.vue and HelloWorld.vue) No ? Use custom theme? Yes ? Use custom properties (CSS variables)? Yes ? Select icon font Material Design Icons ? Use fonts as a dependency (for Electron or offline)? Yes ? Use a-la-carte components? Yes ? Select locale English
🚀 Invoking generator for vue-cli-plugin-vuetify...
ERROR Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists.
Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists.
at Collection.get (C:\Users\lafrance.warren\AppData\Roaming\npm\node_modules\@vue\cli\node_modules\jscodeshift\src\Collection.js:213:13)
at injectOptions (C:\Users\lafrance.warren\AppData\Roaming\npm\node_modules\@vue\cli\lib\util\codemods\injectOptions.js:15:6)
at newTransform (C:\Users\lafrance.warren\AppData\Roaming\npm\node_modules\@vue\cli\node_modules\vue-jscodeshift-adapter\src\jscodeshift-mode.js:9:14)
at runCodemod (C:\Users\lafrance.warren\AppData\Roaming\npm\node_modules\@vue\cli\lib\util\runCodemod.js:29:26)
at Object.keys.forEach.file (C:\Users\lafrance.warren\AppData\Roaming\npm\node_modules\@vue\cli\lib\Generator.js:290:23)
at Array.forEach (
I also confirm, that it was caused by editing public/index.html or src/App.vue and it's component. Thx for help
I am using vue 3 with vue-next and I too am running into this error.
Same problem, any updates here?
Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists.
at Collection.get (/usr/local/lib/node_modules/@vue/cli/node_modules/jscodeshift/src/Collection.js:213:13)
at injectOptions (/usr/local/lib/node_modules/@vue/cli/lib/util/codemods/injectOptions.js:15:6)
at newTransform (/usr/local/lib/node_modules/@vue/cli/node_modules/vue-jscodeshift-adapter/src/jscodeshift-mode.js:9:14)
at runCodemod (/usr/local/lib/node_modules/@vue/cli/lib/util/runCodemod.js:29:26)
at /usr/local/lib/node_modules/@vue/cli/lib/Generator.js:290:23
at Array.forEach (<anonymous>)
at Generator.resolveFiles (/usr/local/lib/node_modules/@vue/cli/lib/Generator.js:276:24)
at processTicksAndRejections (internal/process/task_queues.js:93:5)
at async Generator.generate (/usr/local/lib/node_modules/@vue/cli/lib/Generator.js:175:5)
at async runGenerator (/usr/local/lib/node_modules/@vue/cli/lib/invoke.js:111:3)
Same problem, any updates here?
Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists. at Collection.get (/usr/local/lib/node_modules/@vue/cli/node_modules/jscodeshift/src/Collection.js:213:13) at injectOptions (/usr/local/lib/node_modules/@vue/cli/lib/util/codemods/injectOptions.js:15:6) at newTransform (/usr/local/lib/node_modules/@vue/cli/node_modules/vue-jscodeshift-adapter/src/jscodeshift-mode.js:9:14) at runCodemod (/usr/local/lib/node_modules/@vue/cli/lib/util/runCodemod.js:29:26) at /usr/local/lib/node_modules/@vue/cli/lib/Generator.js:290:23 at Array.forEach (<anonymous>) at Generator.resolveFiles (/usr/local/lib/node_modules/@vue/cli/lib/Generator.js:276:24) at processTicksAndRejections (internal/process/task_queues.js:93:5) at async Generator.generate (/usr/local/lib/node_modules/@vue/cli/lib/Generator.js:175:5) at async runGenerator (/usr/local/lib/node_modules/@vue/cli/lib/invoke.js:111:3)
Are you trying to install vuetify on vue 3?
I'm having the same issue trying to install vue-cli-plugin-vuetify@2.0.7
on vue@2.6.11
.
Does anyone have updates about?
I'm having the same issue trying to install
vue-cli-plugin-vuetify@2.0.7
onvue@2.6.11
. Does anyone have updates about?
I don't think you'll run into this issue if you use vue-cli and do something like 'vue add vuetify'
I think that this is because vue3 beta has that error! I had to change my main.js. I was trying to install vuex
i could solve my problem, there must be the following code in the main.js, otherwise the error will occur. So just add this code before installation:
new Vue({
render: h => h(App),
}).$mount('#app');
The solution of @do-web works fine. Afterwards I removed the
new Vue({
vuetify,
render: h => h(App)
}).$mount('#app')
from my main.js
and added the .use(vuetify)
to
createApp(App)
.use(store)
.use(router)
.mount('#app')
BTW It is not sufficient to leave the piece of code there but commented out, it needs to be real code and not a comment! (Would have been nice)
EDIT: It seems that, even if you get the installation done, the app will not work due major changes of Vue 3 that are inkompatible to Vuetify 1/2.
I'm pretty sure the most recent problems are nothing to do with the vuetify plugin. Seem like most people are coming across this with Vue CLI 4 and vue-next and it just happens to have the same symptoms as described in the original (unrelated) issue. Should probably close this and continue discussion here https://github.com/vuejs/vue-cli
add following code in main.js
new Vue({ vuetify, render: h => h(App) }).$mount('#app');
any update in this issues , i try all the above solution but not work with me ,
Using newer version (^9.0.3), but this may cause build errors.
ERROR Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists.
Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists.
at Collection.get (/usr/local/share/.config/yarn/global/node_modules/jscodeshift/src/Collection.js:213:13)
at injectOptions (/usr/local/share/.config/yarn/global/node_modules/@vue/cli/lib/util/codemods/injectOptions.js:15:6)
at runTransformation (/usr/local/share/.config/yarn/global/node_modules/vue-codemod/dist/src/run-transformation.js:61:17)
at /usr/local/share/.config/yarn/global/node_modules/@vue/cli/lib/Generator.js:290:23
at Array.forEach (
I confirm that @do-web solution works for this problem.
Hello, Just learnt about Vuetify and I'm having the same error. I don't see how @do-web solution fixes any thing as @sense-it-gmbh said, I can't start the server. I have tried to install it via the cli and the ui... just in case... @johnleider : any update since Dec 2019?
Any other idea?
This is my environment (fresh install): ... ae error as everyone else. System: OS: Windows 10 10.0.18363 CPU: (8) x64 Intel(R) Core(TM) i7-4790K CPU @ 4.00GHz Binaries: Node: 12.16.3 - C:\Program Files\nodejs\node.EXE Yarn: Not Found npm: 6.14.4 - C:\Program Files\nodejs\npm.CMD Browsers: Chrome: 84.0.4147.135 Edge: Spartan (44.18362.449.0) npmPackages: @ant-design-vue/babel-helper-vue-transform-on: 1.0.1 @vue/babel-helper-vue-jsx-merge-props: 1.0.0 @vue/babel-plugin-transform-vue-jsx: 1.1.2 @vue/babel-preset-app: 4.5.4 @vue/babel-preset-jsx: 1.1.2 @vue/babel-sugar-functional-vue: 1.1.2 @vue/babel-sugar-inject-h: 1.1.2 @vue/babel-sugar-v-model: 1.1.2 @vue/babel-sugar-v-on: 1.1.2 @vue/cli-overlay: 4.5.4 @vue/cli-plugin-babel: ~4.5.0 => 4.5.4 @vue/cli-plugin-eslint: ~4.5.0 => 4.5.4 @vue/cli-plugin-router: ^4.5.4 => 4.5.4 @vue/cli-plugin-vuex: ^4.5.4 => 4.5.4 @vue/cli-service: ~4.5.0 => 4.5.4 @vue/cli-shared-utils: 4.5.4 @vue/compiler-core: 3.0.0-rc.6 @vue/compiler-dom: 3.0.0-rc.6 @vue/compiler-sfc: ^3.0.0-0 => 3.0.0-rc.6 @vue/compiler-ssr: 3.0.0-rc.6 @vue/component-compiler-utils: 3.2.0 @vue/preload-webpack-plugin: 1.1.2 @vue/reactivity: 3.0.0-rc.6 @vue/runtime-core: 3.0.0-rc.6 @vue/runtime-dom: 3.0.0-rc.6 @vue/shared: 3.0.0-rc.6 @vue/web-component-wrapper: 1.2.0 eslint-plugin-vue: ^7.0.0-0 => 7.0.0-beta.2 vue: ^3.0.0-0 => 3.0.0-rc.6 vue-cli-plugin-vuetify: ~2.0.7 => 2.0.7 vue-eslint-parser: 7.1.0 vue-hot-reload-api: 2.3.4 vue-loader: 15.9.3 (16.0.0-beta.5) vue-router: ^4.0.0-0 => 4.0.0-beta.7 vue-style-loader: 4.1.2 vue-template-es2015-compiler: 1.9.1 vuetify-loader: ^1.3.0 => 1.6.0 vuex: ^4.0.0-0 => 4.0.0-beta.4 npmGlobalPackages: @vue/cli: Not Found
vue: ^3.0.0-0 => 3.0.0-rc.6
Vuetify requires Vue 2 @e3-naibu
Oh! Thought I saw a tutorial with Vuetify and Vue 3... my bad! Thank you.
I think the main issue has the same problem not using vue 2!
@jacekkarczmarczyk thanks :)
Probably, closing as I can't see in the comments any reproduction using Vue 2 (or any reprodution at all)
please, some one can help me, Im using vue cli 4.5.4 and I have so many problems to install veautify and the bootstrap plugins.
� Invoking generator for vue-cli-plugin-vuetify...
ERROR Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists.
Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists.
at Collection.get (C:\Users\Brule\AppData\Roaming\npm\node_modules\@vue\cli\node_modules\jscodeshift\src\Collection.js:213:13)
at injectOptions (C:\Users\Brule\AppData\Roaming\npm\node_modules\@vue\cli\lib\util\codemods\injectOptions.js:15:6)
at runTransformation (C:\Users\Brule\AppData\Roaming\npm\node_modules\@vue\cli\node_modules\vue-codemod\dist\src\run-transformation.js:61:17)
at C:\Users\Brule\AppData\Roaming\npm\node_modules\@vue\cli\lib\Generator.js:290:23
at Array.forEach (
vue3 is giving this error because vue3 is in beta version if you use vue2 you solve your problem. My error is solved by this solution.
Thanks
On Tue, 15 Sep 2020 at 21:13, Joshua Dawi Abejero notifications@github.com wrote:
I just wanna help on how I fixed. I'm using .js not .ts and I'm not sure if the code is the same but I guess the logic might be. So here's how I solve it.
This is the default auto generated file run by the vue create { app name} command. [image: image] https://user-images.githubusercontent.com/29270980/93203576-3cbebc00-f787-11ea-9e65-70072bd97335.png
This is how I modified it. [image: image] https://user-images.githubusercontent.com/29270980/93203649-5bbd4e00-f787-11ea-8e29-404ff22da961.png
Vuetify was installed successfully. [image: image] https://user-images.githubusercontent.com/29270980/93203697-71cb0e80-f787-11ea-9f3d-2ecd4dd8ea62.png
Hope it helps! 😄
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/vuetifyjs/vue-cli-plugins/issues/140#issuecomment-692648301, or unsubscribe https://github.com/notifications/unsubscribe-auth/APQSVLCDQ4DYGAUBWZKW7RTSF5D6JANCNFSM4JXAW5HA .
I faced the same error when adding i18n
to my vue3 app and the solution of @do-web works fine.
@OgunniyiOwamamwen your method does not fix the "No matching rule for vue-loader found"
Which is good news... as that means Typescript isn't the incompatible issue here.
Vuetify 3 is not out yet. That's the one that will have full suport of Vue 3 composition.... Vue 2.6 has defacto support, but not proactive support. Vue 3 only came out in stable last month.
this is not proper solution, still getting errors
Just hit the same issue
Vuetify 2.x doesn't work with Vue 3
I am trying to install Vuetify and I got this:
vue add vuetify
📦 Installing vue-cli-plugin-vuetify...
12 packages are looking for funding run
npm fund
for detailsfound 0 vulnerabilities
✔ Successfully installed plugin: vue-cli-plugin-vuetify
? Choose a preset: Default (recommended)
🚀 Invoking generator for vue-cli-plugin-vuetify... ERROR Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists. Error: You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists. at Collection.get (/usr/lib/node_modules/@vue/cli/node_modules/jscodeshift/src/Collection.js:215:13) at injectOptions (/usr/lib/node_modules/@vue/cli/lib/util/codemods/injectOptions.js:15:6) at newTransform (/usr/lib/node_modules/@vue/cli/node_modules/vue-jscodeshift-adapter/src/jscodeshift-mode.js:9:14) at runCodemod (/usr/lib/node_modules/@vue/cli/lib/util/runCodemod.js:29:26) at /usr/lib/node_modules/@vue/cli/lib/Generator.js:283:23 at Array.forEach ()
at Generator.resolveFiles (/usr/lib/node_modules/@vue/cli/lib/Generator.js:269:24)
at processTicksAndRejections (internal/process/task_queues.js:93:5)
at async Generator.generate (/usr/lib/node_modules/@vue/cli/lib/Generator.js:168:5)
at async runGenerator (/usr/lib/node_modules/@vue/cli/lib/invoke.js:120:3)