Skip to content

Dismiss error overlay when source is fixed #52

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

Closed
Rich-Harris opened this issue Jun 9, 2022 · 6 comments
Closed

Dismiss error overlay when source is fixed #52

Rich-Harris opened this issue Jun 9, 2022 · 6 comments
Milestone

Comments

@Rich-Harris
Copy link
Member

The error overlay behaves a little strangely. If you introduce a syntax error then fix it, the error overlay isn't dismissed. If you add insignificant changes like whitespace, the overlay still isn't dismissed (@dominikg could this be related to this?). Eventually, if you add changes that are significant, the overlay goes away, but it feels like it should vanish as soon as the error is fixed.

error-overlay.mov
@Rich-Harris Rich-Harris added this to the Demo milestone Jun 9, 2022
@dominikg
Copy link
Member

dominikg commented Jun 9, 2022

should not. That only ignores add_location differences. code changes are sent. What causes the close in the end? May be a vite issue. cc @bluwy

@bluwy
Copy link
Member

bluwy commented Jun 9, 2022

The error overlay is auto-closed after another HMR update event is sent:

https://github.com/vitejs/vite/blob/fba82d0ff66d2a13393b052dd95df9e180db663c/packages/vite/src/client/client.ts#L83

It might either be that we didn't re-trigger the update event, or the error was somehow still reported after the update.

@dominikg
Copy link
Member

dominikg commented Jun 9, 2022

@dominikg
Copy link
Member

dominikg commented Jun 9, 2022

PR that fixes it: sveltejs/vite-plugin-svelte#371

(didn't move/ref this issue in v-p-s to avoid spilling info)

@dominikg
Copy link
Member

dominikg commented Jun 9, 2022

Released @sveltejs/[email protected] that includes the pr above

@Rich-Harris
Copy link
Member Author

tested, works great! thanks

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

3 participants