-
Notifications
You must be signed in to change notification settings - Fork 0
/
rollup.config.js
25 lines (23 loc) · 742 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
import { terser } from 'rollup-plugin-terser'
import sizeCheck from 'rollup-plugin-filesize-check'
import pkg from './package.json'// assert { type: "json" };
const name = 'suffix-thumb'
const banner = `/* ${name} ${pkg.version} MIT */`
export default [
{
input: 'src/index.js',
output: [{ file: `builds/${name}.mjs`, format: 'esm', banner: banner },
],
plugins: [sizeCheck()],
},
{
input: 'src/index.js',
output: [{ file: `builds/${name}.js`, format: 'umd', name: 'suffixThumb', banner: banner }],
plugins: [sizeCheck(),],
},
{
input: 'src/index.js',
output: [{ file: `builds/${name}.min.js`, format: 'umd', name: 'suffixThumb', banner: banner }],
plugins: [terser(), sizeCheck(),],
}
]