refactor: cleanup reservation methods scope
[e-mobility-charging-stations-simulator.git] / rollup.config.mjs
index 83c2e009b3d585b1c32afcf611f7cf0bd8046ddb..2c8d35564c05b9925bfaf91e3c39f4aa582abc7d 100644 (file)
@@ -24,6 +24,7 @@ const availableParallelism = () => {
 
 const isDevelopmentBuild = process.env.BUILD === 'development';
 const isAnalyzeBuild = process.env.ANALYZE;
+const sourceMap = !!isDevelopmentBuild;
 
 export default {
   input: ['src/start.ts', 'src/charging-station/ChargingStationWorker.ts'],
@@ -32,7 +33,7 @@ export default {
     {
       dir: 'dist',
       format: 'esm',
-      sourcemap: !!isDevelopmentBuild,
+      sourcemap: sourceMap,
       plugins: [terser({ maxWorkers: Math.floor(availableParallelism() / 2) })],
     },
   ],
@@ -55,6 +56,7 @@ export default {
     'node:events',
     'node:fs',
     'node:http',
+    'node:http2',
     'node:path',
     'node:perf_hooks',
     'node:stream',
@@ -73,7 +75,7 @@ export default {
     typescript({
       tsconfig: 'tsconfig.json',
       compilerOptions: {
-        sourceMap: !!isDevelopmentBuild,
+        sourceMap,
       },
     }),
     del({