forked from nileriver-finance/balancer-sor
-
Notifications
You must be signed in to change notification settings - Fork 0
/
rollup.config.ts
35 lines (32 loc) · 968 Bytes
/
rollup.config.ts
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
import { nodeResolve } from '@rollup/plugin-node-resolve';
import commonjs from '@rollup/plugin-commonjs';
import json from '@rollup/plugin-json';
import typescript from '@rollup/plugin-typescript';
import dts from 'rollup-plugin-dts';
import pkg from './package.json';
const external = [
'@ethersproject/abi',
'@ethersproject/abstract-signer',
'@ethersproject/address',
'@ethersproject/constants',
'@ethersproject/contracts',
'@ethersproject/providers',
'isomorphic-fetch',
'bignumber.js',
];
export default [
{
input: 'src/index.ts',
output: [
{ file: pkg.main, format: 'cjs', sourcemap: true },
{ file: pkg.module, format: 'es', sourcemap: true },
],
plugins: [nodeResolve(), json(), commonjs(), typescript()],
external,
},
{
input: 'src/index.ts',
output: [{ file: 'dist/index.d.ts', format: 'es' }],
plugins: [dts()],
},
];