Skip to content

vue add vue-next 后 HMR 失效 #25

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
ghost opened this issue Apr 26, 2020 · 0 comments
Open

vue add vue-next 后 HMR 失效 #25

ghost opened this issue Apr 26, 2020 · 0 comments

Comments

@ghost
Copy link

ghost commented Apr 26, 2020

环境信息:
1.系统:MacOS Mojave 10.14.5;
2.浏览器:Google Chrome 81.0.4044.122(正式版本,64位,目前最新);
3.NodeJS:v12.16.2;
4.NPM:v6.14.4;
5.Yarn 镜像源地址:https://registry.npmjs.org/;
6.@vue/cli:v4.3.1;
7.Yarn:v1.5.1;

重现步骤:
1.vue create vue3-beta
(1)Please pick a preset -> Manually select features
(2)Check the features needed for your project -> Babel,Router,Vuex,Linter / Formatter
(3)Use history mode for router? -> Y
(4)Pick a linter / formatter config -> ESLint with error prevention only
(5)Pick additional lint features -> Lint on save
(6)Where do you prefer placing config for Babel, ESLint, etc.? -> In dedicated config files
(7)Save this as a preset for future projects? -> N
2.此时 yarn serve 后,更改 /src/views/Home.vue 后,HMR 有效;
3.vue add vue-next
4.此后再进行 yarn serve,更改 /src/views/Home.vue 后,HMR 失效;

现象:
1.HMR 失效,更改 .vue 后浏览器不会自动刷新,手动刷新后试图变更;
2.浏览器控制台,保持打印:[HMR] Waiting for update signal from WDS...,更改 .vue 后打印无变化;

附 package.json 内容:

{
  "name": "vue3-beta",
  "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.4",
    "vue": "^3.0.0-beta.1",
    "vue-router": "^4.0.0-alpha.5",
    "vuex": "^4.0.0-alpha.1"
  },
  "devDependencies": {
    "@vue/cli-plugin-babel": "~4.3.0",
    "@vue/cli-plugin-eslint": "~4.3.0",
    "@vue/cli-plugin-router": "~4.3.0",
    "@vue/cli-plugin-vuex": "~4.3.0",
    "@vue/cli-service": "~4.3.0",
    "@vue/compiler-sfc": "^3.0.0-beta.1",
    "babel-eslint": "^10.1.0",
    "eslint": "^6.7.2",
    "eslint-plugin-vue": "^7.0.0-alpha.0",
    "vue-cli-plugin-vue-next": "~0.1.2"
  }
}

烦请尽快解决,有什么需要配合定位的我这边尽力配合,谢谢!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants