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

fix (client): client will not query document when in no document env #17654

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

nicksrandall
Copy link

Description

I have a webworker (along with a larger frontend app) hooked up to HMR and the vite client script continues to error when trying to update css files because the vite client is querying the document even though it doesn't not exist in a web worker environment. This simple change will not try to update css links in environments where document is not available.

Copy link

stackblitz bot commented Jul 10, 2024

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@nicksrandall nicksrandall changed the title Vite Client (HMR): prevent query of document when no document is available. fix (client): prevent query of document when no document is available. Jul 10, 2024
@nicksrandall nicksrandall changed the title fix (client): prevent query of document when no document is available. fix: client will not query document when in no document env Jul 10, 2024
@nicksrandall nicksrandall changed the title fix: client will not query document when in no document env fix (client): client will not query document when in no document env Jul 16, 2024
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

Successfully merging this pull request may close these issues.

None yet

1 participant