File tree Expand file tree Collapse file tree 3 files changed +4
-21
lines changed
Expand file tree Collapse file tree 3 files changed +4
-21
lines changed Original file line number Diff line number Diff line change 102102 "validate-npm-package-name" : " ^5.0.0"
103103 },
104104 "devDependencies" : {
105- "@esbuild-plugins/node-globals-polyfill" : " ^0.2.3" ,
106- "@esbuild-plugins/node-modules-polyfill" : " ^0.2.2" ,
107105 "@lavamoat/allow-scripts" : " ^3.0.4" ,
108106 "@metamask/auto-changelog" : " ^4.1.0" ,
109107 "@metamask/post-message-stream" : " ^9.0.0" ,
130128 "ts-node" : " ^10.9.1" ,
131129 "typescript" : " ~5.3.3" ,
132130 "vite" : " ^6.2.3" ,
131+ "vite-plugin-node-polyfills" : " ^0.23.0" ,
133132 "vite-tsconfig-paths" : " ^4.0.5" ,
134133 "vitest" : " ^3.0.8"
135134 },
Original file line number Diff line number Diff line change 1- import { NodeGlobalsPolyfillPlugin } from '@esbuild-plugins/node-globals-polyfill' ;
2- import { NodeModulesPolyfillPlugin } from '@esbuild-plugins/node-modules-polyfill' ;
1+ import { nodePolyfills } from 'vite-plugin-node-polyfills' ;
32import tsconfigPaths from 'vite-tsconfig-paths' ;
43import { defineConfig } from 'vitest/config' ;
54
65export default defineConfig ( {
7- plugins : [ tsconfigPaths ( ) ] ,
8-
9- optimizeDeps : {
10- esbuildOptions : {
11- plugins : [
12- // @ts -expect-error: Incompatibility between Vite versions.
13- NodeModulesPolyfillPlugin ( ) ,
14-
15- // @ts -expect-error: Incompatibility between Vite versions.
16- NodeGlobalsPolyfillPlugin ( {
17- buffer : true ,
18- } ) ,
19- ] ,
20- } ,
21- } ,
6+ plugins : [ tsconfigPaths ( ) , nodePolyfills ( ) ] ,
227
238 test : {
249 // Vitest enables watch mode by default. We disable it here, so it can be
Original file line number Diff line number Diff line change @@ -5887,8 +5887,6 @@ __metadata:
58875887 dependencies:
58885888 "@babel/core": "npm:^7.23.2"
58895889 "@babel/types": "npm:^7.23.0"
5890- "@esbuild-plugins/node-globals-polyfill": "npm:^0.2.3"
5891- "@esbuild-plugins/node-modules-polyfill": "npm:^0.2.2"
58925890 "@lavamoat/allow-scripts": "npm:^3.0.4"
58935891 "@metamask/auto-changelog": "npm:^4.1.0"
58945892 "@metamask/base-controller": "npm:^8.0.0"
@@ -5936,6 +5934,7 @@ __metadata:
59365934 typescript: "npm:~5.3.3"
59375935 validate-npm-package-name: "npm:^5.0.0"
59385936 vite: "npm:^6.2.3"
5937+ vite-plugin-node-polyfills: "npm:^0.23.0"
59395938 vite-tsconfig-paths: "npm:^4.0.5"
59405939 vitest: "npm:^3.0.8"
59415940 languageName: unknown
You can’t perform that action at this time.
0 commit comments