Skip to content
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

HMR Not Reloading Modifications to External Typescript File #297

Closed
8 of 9 tasks
tehomen opened this issue Nov 16, 2023 · 1 comment
Closed
8 of 9 tasks

HMR Not Reloading Modifications to External Typescript File #297

tehomen opened this issue Nov 16, 2023 · 1 comment

Comments

@tehomen
Copy link

tehomen commented Nov 16, 2023

Related plugins

Describe the bug

When importing a ts file into a vue file vite at first will do hmr properly and you'll see the page refresh when making edits to the ts file, but once you make a change to the vue template hmr no longer works when editing that ts file. You will see in the node console "[vite] hmr update ..." and in the browser console "[vite] hot updated: ...", but the page never updates with the changes made to the ts file.

Reproduction

https://stackblitz.com/edit/vitejs-vite-vmmtoz?file=src%2Ftest.ts

Steps to reproduce

Initial Check:

  1. Go to the file "test.ts"
  2. Uncomment line number 9
  3. You will see the change appear in the page.

Everything will seem to be working fine, now do the following after the initial check:

Breaking HMR:

Break HMR:

  1. Go to the file App.vue
  2. Uncomment line number 6
  3. You will see the page update (but now HMR is broken)

Check Result of Breaking HMR:

  1. Go back to the file "test.ts"
  2. Comment line number 9
  3. You will see that the page remains the same as before commenting.

System Info

Windows 10
Edge Browser

Used Package Manager

npm

Logs

No response

Validations

@yyx990803
Copy link
Member

This is a Vue core issue and is no longer reproducible in latest (3.3.13)

@github-actions github-actions bot locked and limited conversation to collaborators Jan 10, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants