Duplicate HMR reloads when using large collections
Opened this issue · 0 comments
KianNH commented
Astro Info
Astro v5.0.7
Node v22.12.0
System macOS (arm64)
Package Manager npm
Output static
Adapter none
Integrations @astrojs/mdx
If this issue only occurs in one browser, which browser is a problem?
No response
Describe the Bug
Using the same reproduction as #12702, following the fix in #12715, HMR is triggered several times upon a single change.
It appears that some reloads are too early, as they will show the old content, and only the later reload will show the new content.
In the below video, the final edit takes ~30 seconds per reload but the first reload shows the same content as before.
Screen.Recording.2024-12-16.at.18.37.28.mp4
What's the expected result?
Only a single reload happens, with the updated content.
Link to Minimal Reproducible Example
https://stackblitz.com/edit/github-mtk5uaws
Participation
- I am willing to submit a pull request for this issue.