Rollup Setup / Migration

This commit is contained in:
Felix Kaspar
2024-01-26 16:26:04 +01:00
parent c07e247a2a
commit bcb8ff5843
17 changed files with 1288 additions and 1820 deletions

View File

@@ -0,0 +1,28 @@
import run from "@rollup/plugin-run";
import typescript from '@rollup/plugin-typescript';
import json from '@rollup/plugin-json';
import copy from 'rollup-plugin-copy'
const isDev = process.env.NODE_ENV !== "production";
export default {
input: "src/index.ts",
output: {
file: "dist/bundle.js",
format: "es",
},
watch: {
include: [ './src/**', '../shared-operations/src/**' ]
},
plugins: [
json(),
typescript(),
copy({
targets: [
{ src: '../shared-operations/public', dest: 'dist' },
]
}),
isDev && run()
],
};