24 lines
455 B
JavaScript
24 lines
455 B
JavaScript
import typescript from "rollup-plugin-typescript2";
|
|
import resolve from "@rollup/plugin-node-resolve";
|
|
import commonjs from "@rollup/plugin-commonjs";
|
|
|
|
export default {
|
|
input: 'src/index.ts',
|
|
output: [
|
|
{
|
|
file: "dist/index.esm.js",
|
|
format: "es",
|
|
},
|
|
{
|
|
file: "dist/index.cjs",
|
|
format: "cjs",
|
|
}
|
|
],
|
|
plugins: [
|
|
typescript({
|
|
useTsconfigDeclarationDir: true,
|
|
}),
|
|
resolve(),
|
|
commonjs(),
|
|
],
|
|
}; |