-
Notifications
You must be signed in to change notification settings - Fork 14
/
rollup.config.js
38 lines (37 loc) · 1.12 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
import babel from "rollup-plugin-babel";
import multidest from "rollup-plugin-multidest";
import nodeResolve from "rollup-plugin-node-resolve";
import uglify from "rollup-plugin-uglify";
import license from "rollup-plugin-license";
export default {
entry: "src/index.js",
dest: "dist/kero.js",
format: "iife",
moduleName: "bar",
plugins: [
license({
banner: `<%= pkg.name %> v<%= pkg.version %>
<%= pkg.description %>
author : <%= pkg.author %>
homepage : <%= pkg.homepage %>
bugs : <%= pkg.bugs.url %>`,
}),
nodeResolve(),
multidest([
// targets "main" in package.json
// {
// dest: "dist/js/tinper-neoui.cjs.js",
// format: "cjs"
// },
// targets browsers
{
dest: "dist/kero.min.js",
format: "iife",
plugins: [uglify()]
}
]),
babel({
exclude: "node_modules/**" // only transpile our source code
})
]
};