You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a worker file includes react string and a function, react-refresh code including /@vite/client which references HTMLElement will be injected to the worker code, causing Uncaught ReferenceError: HTMLElement is not defined .
Describe the bug
If a worker file includes
react
string and a function, react-refresh code including/@vite/client
which referencesHTMLElement
will be injected to the worker code, causingUncaught ReferenceError: HTMLElement is not defined
.vite/packages/plugin-react-refresh/index.js
Lines 70 to 74 in be9bc3f
Reproduction
https://github.com/buffaybu/vite-env-example/tree/react-refresh (react-refresh branch)
Replace
"react"
with"1"
and the error is gone.System Info
@vitejs/plugin-react-refresh
version: 1.1.3vite
version: 2.0.0-beta.50The text was updated successfully, but these errors were encountered: