Skip to content

Commit 6058493

Browse files
shulaodasapphi-red
andauthored
feat(native-plugin): avoid presetting process.env.NODE_ENV when platform is browser (#290)
Co-authored-by: 翠 <[email protected]>
1 parent 9b5e32a commit 6058493

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/vite/src/node/plugins/define.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ export function definePlugin(config: ResolvedConfig): Plugin {
118118
)
119119
define['import.meta.env'] = importMetaEnvVal
120120
define['import.meta.env.*'] = 'undefined'
121-
option.define = define
121+
option.define = { ...option.define, ...define }
122122
},
123123
}
124124
}

0 commit comments

Comments
 (0)