kunkun/apps/create-kunkun/rollup.config.js
Huakun Shen 5ead38bf71
Add extension templates, create-kunkun and cli package (#26)
* chore: add extension templates

* feat: add create-kunkun and cli package

* fix: cli and create-kunkun package location

* fix: cli package test

* ci: run test for CI pipeline only on Linux

The most important E2E test is run with docker, Linux anyways, no need to run on Mac and Windows
2024-11-15 18:15:17 -05:00

33 lines
809 B
JavaScript

import commonjs from "@rollup/plugin-commonjs"
import json from "@rollup/plugin-json"
import resolve from "@rollup/plugin-node-resolve"
import replace from "@rollup/plugin-replace"
import terser from "@rollup/plugin-terser"
import typescript from "@rollup/plugin-typescript"
import { visualizer } from "rollup-plugin-visualizer"
/** @type {import('rollup').RollupOptions} */
const config = {
input: "index.ts", // Path to your worker file
output: {
file: "dist/index.cjs",
format: "cjs"
},
plugins: [
replace({
preventAssignment: true,
"process.env.NODE_ENV": JSON.stringify(process.env.NODE_ENV || "production")
}),
json(),
typescript(),
resolve({
preferBuiltins: true
}),
commonjs(),
terser(),
visualizer()
]
}
export default config