Skip to content

Commit aafc3e1

Browse files
committed
fix: import.meta SSR
#fix 802
1 parent 7becca9 commit aafc3e1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

rollup.config.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ function createReplacePlugin(
192192
__SSR__: isBrowserBuild
193193
? false
194194
: isBundlerESMBuild
195-
? `(('process' in globalThis ? globalThis.process.env.SSR : 'import' in globalThis ? globalThis.import.meta.env.SSR : false) == true)`
195+
? `((globalThis.import ? globalThis.import.meta.env.SSR : process.env.SSR ) == true)`
196196
: true,
197197
// this is only used during tests
198198
__TEST__: isBundlerESMBuild ? `(process.env.NODE_ENV === 'test')` : false,

0 commit comments

Comments
 (0)