-
Notifications
You must be signed in to change notification settings - Fork 29
/
rollup.config.js
39 lines (37 loc) · 932 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
import buble from 'rollup-plugin-buble';
import resolve from 'rollup-plugin-node-resolve';
import commonjs from 'rollup-plugin-commonjs';
import liveReload from 'rollup-plugin-livereload';
import serve from 'rollup-plugin-serve';
import uglify from 'rollup-plugin-uglify';
import string from 'rollup-plugin-string';
const PORT = 8080;
// console.log(`open http://localhost:${PORT}/`);
export default {
entry: 'index.js',
sourceMap: true,
targets: [
{
format: 'umd',
moduleName: 'dl',
dest: `dist/template.js`,
}
],
plugins: [
resolve({
jsnext: true,
browser: true,
}),
string({
include: ["**/*.txt", "**/*.svg", "**/*.html", "**/*.css", "**/*.base64"]
}),
buble({
exclude: 'node_modules',
target: { chrome: 52, safari: 8, edge: 13, firefox: 48, }
}),
commonjs(),
// uglify(),
// liveReload(),
// serve({port: PORT}),
]
};