vuetifyjs / vue-cli-plugins

🔌 A collection of Vuetify plugins for Vue CLI
https://vuetifyjs.com/en/getting-started/quick-start#vue-cli-3
Other
428 stars 113 forks source link

vue add vuetify success,but ERROR:You cannot call "get" on a collection with no paths. Instead, check the "length" property first to verify at least 1 path exists. #200

Closed mengqiui closed 4 years ago

mengqiui commented 4 years ago

@vue/cli:4.5.4 node:10.15.3

package.json:

{ "name": "web-vuetify", "version": "0.1.0", "private": true, "scripts": { "serve": "vue-cli-service serve", "build": "vue-cli-service build", "lint": "vue-cli-service lint" }, "dependencies": { "core-js": "^3.6.5", "vue": "^3.0.0-0" }, "devDependencies": { "@vue/cli-plugin-babel": "~4.5.0", "@vue/cli-plugin-eslint": "~4.5.0", "@vue/cli-service": "~4.5.0", "@vue/compiler-sfc": "^3.0.0-0", "babel-eslint": "^10.1.0", "eslint": "^6.7.2", "eslint-plugin-vue": "^7.0.0-0", "vue-cli-plugin-vuetify": "~2.0.7" }, "eslintConfig": { "root": true, "env": { "node": true }, "extends": [ "plugin:vue/vue3-essential", "eslint:recommended" ], "parserOptions": { "parser": "babel-eslint" }, "rules": {} }, "browserslist": [ "> 1%", "last 2 versions", "not dead" ] }

$ vue create web-vuetify ? Please pick a preset: (Use arrow keys) ? Please pick a preset: Default (Vue 3 Preview) ([Vue 3] babel, eslint) ? Pick the package manager to use when installing dependencies: (Use arrow keys) ? Pick the package manager to use when installing dependencies: NPM ✨ Creating project in C:\Users\81089\Desktop\web-vuetify. 🗃 Initializing git repository... ⚙️ Installing CLI plugins. This might take a while...

yorkie@2.0.0 install C:\Users\81089\Desktop\web-vuetify\node_modules\yorkie node bin/install.js

setting up Git hooks done

core-js@3.6.5 postinstall C:\Users\81089\Desktop\web-vuetify\node_modules\core -js node -e "try{require('./postinstall')}catch(e){}"

ejs@2.7.4 postinstall C:\Users\81089\Desktop\web-vuetify\node_modules\ejs node ./postinstall.js

added 1228 packages from 918 contributors and audited 1231 packages in 281.023s found 0 vulnerabilities

🚀 Invoking generators... 📦 Installing additional dependencies...

added 70 packages from 46 contributors and audited 1301 packages in 46.498s found 0 vulnerabilities

⚓ Running completion hooks...

📄 Generating README.md...

🎉 Successfully created project web-vuetify. 👉 Get started with the following commands:

$ cd web-vuetify $ npm run serve

$ cd web-vuetify

$ vue add vuetify WARN There are uncommitted changes in the current repository, it's recommended to commit or stash them first. ? Still proceed? (y/N) y ? Still proceed? Yes

📦 Installing vue-cli-plugin-vuetify...

✔ Successfully installed plugin: vue-cli-plugin-vuetify

? Choose a preset: (Use arrow keys) ? Choose a preset: Prototype (rapid development)

🚀 Invoking generator for vue-cli-plugin-vuetify... ERROR Error: You cannot call "get" on a collection with no paths. Instead, che ck 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\81089\AppData\Roaming\npm\node_modules\@vue\cli\ node_modules\jscodeshift\src\Collection.js:213:13) at injectOptions (C:\Users\81089\AppData\Roaming\npm\node_modules\@vue\cli\l ib\util\codemods\injectOptions.js:15:6) at runTransformation (C:\Users\81089\AppData\Roaming\npm\node_modules\@vue\c li\node_modules\vue-codemod\dist\src\run-transformation.js:61:17) at Object.keys.forEach.file (C:\Users\81089\AppData\Roaming\npm\node_modules \@vue\cli\lib\Generator.js:290:23) at Array.forEach () at Generator.resolveFiles (C:\Users\81089\AppData\Roaming\npm\node_modules\@ vue\cli\lib\Generator.js:276:24) at process._tickCallback (internal/process/next_tick.js:68:7)

jacekkarczmarczyk commented 4 years ago

Duplicate of https://github.com/vuetifyjs/vue-cli-plugins/issues/140

TL;DR - use Vue 2

PachVerb commented 4 years ago

Duplicate of #140

TL;DR - use Vue 2

Why do you have to use vuE2, you can't use vuetify in vuE3

DRoet commented 4 years ago

no Vuetify is not compatible yet with Vue 3, see https://vuetifyjs.com/en/introduction/roadmap/

jacekkarczmarczyk commented 4 years ago

no Vuetify is not compatible yet with Vue 2

Vue 3 ;)

PachVerb commented 4 years ago

no Vuetify is not compatible yet with Vue 2, see https://vuetifyjs.com/en/introduction/roadmap/

no Vuetify is not compatible yet with Vue 2, see https://vuetifyjs.com/en/introduction/roadmap/

Thank you, I see. But I'm talking vue3 here, It's compatible in Vue2

DRoet commented 4 years ago

whoops unfortunate typo 😅

FotieMConstant commented 3 years ago

I had this same issue and had to roll back to vue 2

ungarson commented 3 years ago
Screenshot 2021-02-26 at 20 52 53

Try choosing preset «Configure (advanced)»

This preset might work for you:

? Use a pre-made template? (will replace App.vue and HelloWorld.vue) No
? Use custom theme? No
? Use custom properties (CSS variables)? Yes
? Select icon font Material Design Icons
? Use fonts as a dependency (for Electron or offline)? No
? Use a-la-carte components? Yes
? Select locale English
qianyidai commented 3 years ago
Screenshot 2021-02-26 at 20 52 53

Try choosing preset «Configure (advanced)» This preset might work for you:

? Use a pre-made template? (will replace App.vue and HelloWorld.vue) No
? Use custom theme? No
? Use custom properties (CSS variables)? Yes
? Select icon font Material Design Icons
? Use fonts as a dependency (for Electron or offline)? No
? Use a-la-carte components? Yes
? Select locale English

still doesn't work image

EdsonCarvalho24 commented 3 years ago

Tenta mudar para vue 2 Tenho a certeza que estás a usar vue 3 E o vuetify só instala no vue 2.

qianyidai commented 3 years ago

Tenta mudar para vue 2 Tenho a certeza que estás a usar vue 3 E o vuetify só instala no vue 2.

this version of Vuetify can be used only in vue2. https://vuetifyjs.com/en/introduction/roadmap/#in-development

erkin7333 commented 2 years ago

? Choose a preset: Default (recommended) Using newer version (^1.49.7), 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.

Please help correct this error