-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrollup.config.js
45 lines (44 loc) · 928 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
41
42
43
44
45
import alias from '@rollup/plugin-alias';
import babel from "@rollup/plugin-babel";
import cleanup from "rollup-plugin-cleanup";
import nodeResolve from "@rollup/plugin-node-resolve";
import path from "path";
export default {
input: "src/index.ts",
output: [
{
file: "lib/index.js",
format: "cjs",
exports: "auto"
},
{
file: "dist/index.js",
format: "es"
}
],
external: [
/@babel\/runtime/,
/solid-js/,
/@orbit\/data/,
/@orbit\/memory/,
/@orbit\/record-cache/
],
plugins: [
nodeResolve({
extensions: [".js", ".ts", ".tsx"]
}),
alias({
resolve: [
{ find: 'solid-orbit', replacement: path.resolve(__dirname, "src") }
]
}),
babel({
extensions: [".js", ".ts", ".tsx"],
exclude: "node_modules/**",
babelHelpers: "runtime"
}),
cleanup({
extensions: [".js", ".ts"]
})
]
}