23 lines
445 B
JavaScript
23 lines
445 B
JavaScript
import { defineConfig } from "rollup"
|
|
import ts from "rollup-plugin-ts"
|
|
import pkg from "./package.json" assert { type: "json" }
|
|
|
|
|
|
export default defineConfig({
|
|
input: "src/index.ts",
|
|
|
|
plugins: [ ts() ],
|
|
|
|
output: [
|
|
{
|
|
file: pkg.exports["."].import.default,
|
|
format: "esm",
|
|
},
|
|
|
|
{
|
|
file: pkg.exports["."].require.default,
|
|
format: "cjs",
|
|
},
|
|
],
|
|
})
|