-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrollup.config.js
40 lines (38 loc) · 972 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
40
import replace from '@rollup/plugin-replace'
// import externalGlobals from "rollup-plugin-external-globals"
import pkg from './package.json'
export default {
input: 'src/rollup.js',
context: 'window',
output: {
name: 'layers.p5',
file: 'dist/layers.p5.js',
format: 'umd',
banner: `/**
* layers.p5.js
* ---
* https://twitter.com/heyozramos
* https://github.com/ozramos/layers.p5
* ---
* @version ${pkg.version}
* @license "Apache 2.0"
* ---
* This file was bundled with Rollup
*/`
},
plugins: [
replace({
preventAssignment: true,
values: {
'NPM_PACKAGE_VERSION': pkg.version,
// @FIXME This is to remove the annoying warning about poly-decomp
'isConcave && !canDecomp': 'false',
}
}),
// externalGlobals({
// 'tweakpane': 'Tweakpane',
// '@tweakpane/plugin-essentials': 'EssentialsPlugin',
// })
],
// external: ['tweakpane', '@tweakpane/plugin-essentials'],
}