-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrollup.config.js
More file actions
26 lines (24 loc) · 643 Bytes
/
rollup.config.js
File metadata and controls
26 lines (24 loc) · 643 Bytes
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
import { babel } from '@rollup/plugin-babel'
import eslint from '@rollup/plugin-eslint'
import terser from '@rollup/plugin-terser'
import scss from 'rollup-plugin-scss'
import dynamicImportVars from '@rollup/plugin-dynamic-import-vars'
import del from 'rollup-plugin-delete'
const config = {
input: 'src/index.js',
output: {
dir: `dist/`,
format: 'esm',
},
plugins: [
del({ targets: 'dist/*' }),
scss({
output: false,
}),
dynamicImportVars(),
eslint(),
babel({ babelHelpers: 'bundled', exclude: 'node_modules/**' }),
process.env.production === 'on' && terser(),
],
}
export default config