Upgraded project (Vue2->Vue3) fails to build for production #13018
-
After following the migration guide as described in https://v3-migration.vuejs.org/ everything works fine when running the development server with 'yarn run serve'. If I try to build it for production with 'yarn build' the build fails. (see the errors in the attachments) Hope that someone can help me with this. Best regards, |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
It looks like it's failing because you're using a version of ESLint that's too new. I believe the It will build if you skip ESLint, e.g. by changing the "build": "vue-cli-service build --skip-plugins @vue/cli-plugin-eslint", To get ESLint working, I suggest creating a new project using Vue CLI and copying the dependency versions from that. Longer term you'll likely want to make the switch to Vite. |
Beta Was this translation helpful? Give feedback.
It looks like it's failing because you're using a version of ESLint that's too new. I believe the
extensions
option was removed in ESLint 9, but Vue CLI doesn't seem to have been updated to account for that.It will build if you skip ESLint, e.g. by changing the
build
inscripts
to:To get ESLint working, I suggest creating a new project using Vue CLI and copying the dependency versions from that.
Longer term you'll likely want to make the switch to Vite.