aboutsummaryrefslogtreecommitdiff
path: root/rollup.config.js
blob: bcdea49ba6864a9a996d05cf2b07832c84569196 (plain) (blame)
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
import json from "@rollup/plugin-json";
import typescript from "@rollup/plugin-typescript";
import { terser } from "rollup-plugin-terser";

module.exports = {
	input: {
		"javascript": "src/javascript.ts",
		"react-javascript": "src/react-javascript.ts",
		"react-typescript": "src/react-typescript.ts",
		"typescript": "src/typescript.ts",
		"vue-javascript": "src/vue-javascript.ts",
		"vue-typescript": "src/vue-typescript.ts",
	},
	output: {
		dir: ".",
		entryFileNames: "[name].js",
		format: "cjs",
	},
	plugins: [
		json({
			compact: true,
			namedExports: false,
		}),
		typescript(),
		terser({
			compress: true,
			output: {
				comments: false,
			},
		}),
	],
};