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 0a367b6 commit 9572d40Copy full SHA for 9572d40
src/plugins/hydration.ts
@@ -21,7 +21,9 @@ export const InjectHydrationPlugin = createUnplugin(() => {
21
include: /.(vue|ts|js|tsx|jsx)$/,
22
exclude: [skipPath, EXCLUDE_NODE_MODULES],
23
},
24
- code: /defineNuxtComponent|defineComponent/,
+ code: {
25
+ include: [DEFINE_COMPONENT_RE, DEFINE_NUXT_COMPONENT_RE],
26
+ },
27
28
async handler(code, id) {
29
const m = new MagicString(code)
@@ -90,7 +92,9 @@ export const InjectHydrationPlugin = createUnplugin(() => {
90
92
include: INCLUDE_VUE_RE,
91
93
94
- code: /(?!defineComponent|defineNuxtComponent)/,
95
96
+ exclude: [DEFINE_COMPONENT_RE, DEFINE_NUXT_COMPONENT_RE],
97
98
99
100
handler(code, id) {
0 commit comments