build: properly account build time
[e-mobility-charging-stations-simulator.git] / bundle.js
index dea5a97f58449ec15ef63971d195ac9cded35e33..ec12c5da80190df2696f816bae9a3f6015202084 100644 (file)
--- a/bundle.js
+++ b/bundle.js
@@ -10,8 +10,8 @@ const isDevelopmentBuild = env.BUILD === 'development';
 const sourcemap = !!isDevelopmentBuild;
 
 console.info(chalk.green(`Building in ${isDevelopmentBuild ? 'development' : 'production'} mode`));
-console.time('Build time');
 (async () => {
+  console.time('Build time');
   await build({
     entryPoints: ['./src/start.ts', './src/charging-station/ChargingStationWorker.ts'],
     bundle: true,
@@ -74,5 +74,5 @@ console.time('Build time');
       }),
     ],
   });
+  console.timeEnd('Build time');
 })();
-console.timeEnd('Build time');