Fixed ethers imported in web workers (#3856).

This commit is contained in:
Richard Moore 2023-03-07 02:07:03 -05:00
parent abeaa74da0
commit 5f2678fb05

@ -13,11 +13,12 @@ function getConfig(opts) {
input: "./lib.esm/index.js",
output: {
file,
banner: "const __$G = (typeof globalThis !== 'undefined' ? globalThis: typeof window !== 'undefined' ? window: typeof global !== 'undefined' ? global: typeof self !== 'undefined' ? self: {});",
name: (opts.name || undefined),
format: (opts.format || "esm"),
sourcemap: true
},
context: "window",
context: "__$G",
treeshake: false,
plugins: [ nodeResolve({
exportConditions,