-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathrollup.config.js
More file actions
29 lines (28 loc) · 782 Bytes
/
rollup.config.js
File metadata and controls
29 lines (28 loc) · 782 Bytes
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
import cleaner from "rollup-plugin-cleaner";
import external from "rollup-plugin-peer-deps-external";
import resolve from "@rollup/plugin-node-resolve";
import ts from "rollup-plugin-ts";
import { terser } from "rollup-plugin-terser";
import { visualizer } from "rollup-plugin-visualizer";
export default {
input: ["src/index.ts"],
output: {
dir: "lib",
format: "es",
preserveModules: true,
preserveModulesRoot: "src",
sourcemap: true,
validate: true
},
plugins: [
cleaner({
targets: ["lib"]
}),
external(),
resolve(),
ts({ browserslist: false, transpiler: "babel" }),
terser(),
visualizer({ filename: "stories/.lib.stats.html" })
],
external: ["@fluentui/react", "date-fns", "lodash", "react", "react-dom"]
};