-
Notifications
You must be signed in to change notification settings - Fork 61
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
use globalThis instead of window in HMR #134
base: master
Are you sure you want to change the base?
Conversation
This fixes for more context: https://wintercg.org/
|
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## master #134 +/- ##
==========================================
- Coverage 94.80% 94.75% -0.06%
==========================================
Files 24 24
Lines 2041 2115 +74
Branches 321 330 +9
==========================================
+ Hits 1935 2004 +69
- Misses 106 111 +5
☔ View full report in Codecov by Sentry. |
Co-authored-by: antoniopresto <antoniopresto@gmail.com>
+1 tested quickly via this loader and it fixed {
test: /node_modules[\\/]@ant-design[\\/]cssinjs[\\/]es[\\/]hooks[\\/]useHMR\.js$/, // https://github.com/ant-design/cssinjs/issues/133
loader: "string-replace-loader",
options: {
search: "window",
replace: "globalThis",
flags: "g",
},
}, |
Hi! Do you need any help on this? :) |
Usage of
window
in non-browser env, breaks