We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f579b37 commit 1e2327fCopy full SHA for 1e2327f
packages/common/refresh-utils.ts
@@ -100,7 +100,8 @@ export function virtualPreamblePlugin({
100
},
101
transform: {
102
filter: { code: /__REACT_DEVTOOLS_GLOBAL_HOOK__/ },
103
- handler(code) {
+ handler(code, _id, options) {
104
+ if (options?.ssr) return
105
// this is expected to be either `react` or `react-dom/client`
106
if (isEnabled() && code.includes('__REACT_DEVTOOLS_GLOBAL_HOOK__')) {
107
return `import ${JSON.stringify(name)};` + code
0 commit comments