-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathrollup.config.js
42 lines (42 loc) · 994 Bytes
/
rollup.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
import json from "@rollup/plugin-json";
import nodePolyfills from "rollup-plugin-node-polyfills";
import inject from "@rollup/plugin-inject";
import typescript from "rollup-plugin-typescript2";
export default {
input: "src/index.ts",
output: [
{
file: "dist/bundle.es5.js",
format: "es",
globals: {
ethers: "ethers",
"@walletconnect/web3-provider": "WalletConnectProvider",
},
},
{
file: "dist/bundle.umd.js",
format: "umd",
name: "Auth",
globals: {
ethers: "ethers",
"@walletconnect/web3-provider": "WalletConnectProvider",
},
},
],
external: ["ethers", "@walletconnect/web3-provider"],
plugins: [
nodePolyfills(),
inject({
modules: {
process: "process-es6",
Buffer: ["buffer", "Buffer"],
},
}),
typescript({
useTsconfigDeclarationDir: true,
objectHashIgnoreUnknownHack: false,
clean: true,
}),
json(),
],
};