-
-
Notifications
You must be signed in to change notification settings - Fork 3.5k
V6 Regression - HMR broken when for dynamic imports #16522
Copy link
Copy link
Closed
Labels
- P4: importantViolate documented behavior or significantly impacts performance (priority)Violate documented behavior or significantly impacts performance (priority)fix pending verificationReporter needs to verify the triage bot fix worksReporter needs to verify the triage bot fix workspkg: astroRelated to the core `astro` package (scope)Related to the core `astro` package (scope)
Metadata
Metadata
Assignees
Labels
- P4: importantViolate documented behavior or significantly impacts performance (priority)Violate documented behavior or significantly impacts performance (priority)fix pending verificationReporter needs to verify the triage bot fix worksReporter needs to verify the triage bot fix workspkg: astroRelated to the core `astro` package (scope)Related to the core `astro` package (scope)
Type
Fields
Give feedbackNo fields configured for issues without a type.
Astro Info
If this issue only occurs in one browser, which browser is a problem?
No response
Describe the Bug
Given
./content/one.astro:In Astro 5.18.1, all three patterns below trigger HMR on save of one.astro.
In Astro 6.1.10, only the first does. Furthermore, manual refresh also doesn't work in 6.1.10, it seems to be serving a cached result.
Pattern 1: static import used directly in template. Works on 5.18.1 and 6.1.10
Pattern 2: static import passed as a prop via getStaticPaths. Works on 5.18.1, does NOT work on 6.1.10
Pattern 3: dynamic import resolved at request time. Works on 5.18.1, does NOT work on 6.1.10
This all may be related to #16342, #16000, #15983
What's the expected result?
Dynamic imports should work in Astro 6 as they previously worked in Astro 5.
Link to Minimal Reproducible Example
https://stackblitz.com/edit/github-rnnrmrdl?file=src%2Fpages%2Fcontent%2Fone.astro
Participation