forked from mattiacoll/vanilla-marquee
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrollup.config.js
executable file
·58 lines (57 loc) · 1.34 KB
/
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
import resolve from '@rollup/plugin-node-resolve';
import commonjs from '@rollup/plugin-commonjs';
import { terser } from 'rollup-plugin-terser';
import eslint from '@rollup/plugin-eslint';
export default [
// Custom per tutte le pagine
{
input: 'src/vanilla-marquee.js',
output: [{
plugins: [
terser({
mangle: {
properties: {
regex: /^_*/,
reserved: [
'css3easing',
'delayBeforeStart',
'direction',
'duplicated',
'duration',
'gap',
'pauseOnHover',
'recalcResize',
'speed',
'startVisible',
]
},
},
}),
],
dir: 'dist/',
format: 'es',
indent: false,
entryFileNames: '[name].min.js',
}, {
dir: 'dist/',
format: 'es',
indent: false,
entryFileNames: '[name].js',
}],
context: 'window',
plugins: [
eslint(),
resolve({
browser: true,
modules: true,
preferBuiltins: false,
}),
commonjs({
include: [
/node_modules/,
], // Default: undefined
sourceMap: false,
}),
],
},
];