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.
@vitejs/plugin-react-swc/preamble
1 parent 5907c63 commit 897a3beCopy full SHA for 897a3be
packages/plugin-react-swc/src/index.ts
@@ -75,7 +75,7 @@ type Options = {
75
}
76
77
const react = (_options?: Options): Plugin[] => {
78
- let hmrDisabled = false
+ let hmrDisabled = true
79
let viteCacheRoot: string | undefined
80
const options = {
81
jsxImportSource: _options?.jsxImportSource ?? 'react',
@@ -133,7 +133,7 @@ const react = (_options?: Options): Plugin[] => {
133
}),
134
configResolved(config) {
135
viteCacheRoot = config.cacheDir
136
- if (config.server.hmr === false) hmrDisabled = true
+ hmrDisabled = config.server.hmr === false
137
const mdxIndex = config.plugins.findIndex(
138
(p) => p.name === '@mdx-js/rollup',
139
)
0 commit comments