@omnia/tooling-vue 8.0.332-dev → 8.0.334-dev

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -462,10 +462,63 @@ function bundleManifest(entries) {
462
462
  var vueWebpackConfig = createVueWebpackConfig(entry, entries, $.tooling.composer.OmniaOutput.OutputBundlePath);
463
463
  webpackConfigs.push(vueWebpackConfig);
464
464
  });
465
- // $.tooling.logTime('Build Webpack Config - done', startTime);
465
+ // run on each batch 500 manifets to prevent memory leak and perf
466
+ // let start = 0
467
+ // let end = webpackConfigs.length > 500 ? 500 : webpackConfigs.length
468
+ // function recursiveCompile() {
469
+ // let compiler = $.webpack(webpackConfigs.slice(start, end))
470
+ // compiler.run((err, stats) => {
471
+ // if (err) {
472
+ // $.tooling.log('Bundle manifest error : \r\n', $.tooling.LogTypes.Error);
473
+ // $.tooling.log(err.stack || err, $.tooling.LogTypes.Error);
474
+ // reject();
475
+ // //compiler.close((err, result) => { })
476
+ // return;
477
+ // }
478
+ // if (stats.hasErrors()) {
479
+ // $.tooling.log('Bundle manifest have error : \r\n', $.tooling.LogTypes.Error);
480
+ // let errors = stats.toJson().errors;
481
+ // errors.forEach((err: any) => {
482
+ // $.tooling.log(err.stack || err, $.tooling.LogTypes.Error);
483
+ // })
484
+ // reject();
485
+ // //compiler.close((err, result) => { })
486
+ // return;
487
+ // }
488
+ // compiler.close((err, result) => { });
489
+ // compiler = null;
490
+ // if (end === webpackConfigs.length) {
491
+ // if (checkDuplicateBundle()) { // detect duplicated bundle
492
+ // $.tooling.log('Bundle manifest have error that found duplicated bundles', $.tooling.LogTypes.Error);
493
+ // reject();
494
+ // //compiler.close((err, result) => { })
495
+ // return;
496
+ // }
497
+ // // merge stylex.css
498
+ // const stylexFiles: string[] = globbySync([`${$.tooling.utils.root($.tooling.composer.OmniaOutput.OutputBundlePath).replace(/\\/g, "/")}/*.stylex.css`]);
499
+ // stylexFiles?.forEach(stylexFilePath => {
500
+ // const manifestCssFilePath = stylexFilePath.replace(".stylex.css", ".css");
501
+ // const styelxCss = fsExtra.readFileSync(stylexFilePath, 'utf8');
502
+ // if (!fsExtra.existsSync(manifestCssFilePath)) {
503
+ // fsExtra.outputFileSync(manifestCssFilePath, styelxCss);
504
+ // } else {
505
+ // const css = fsExtra.readFileSync(manifestCssFilePath, 'utf8');
506
+ // fsExtra.outputFileSync(manifestCssFilePath, `${styelxCss}
507
+ // ${css}`);
508
+ // }
509
+ // fsExtra.removeSync(stylexFilePath);
510
+ // });
511
+ // resolve(entries)
512
+ // } else {
513
+ // start = start + 500;
514
+ // end = (end + 500) > webpackConfigs.length ? webpackConfigs.length : end + 500
515
+ // recursiveCompile();
516
+ // }
517
+ // });
518
+ // }
519
+ // recursiveCompile();
466
520
  let compiler = $.webpack(webpackConfigs);
467
521
  compiler.run((err, stats) => {
468
- //console.log("webpack run -done")
469
522
  if (checkDuplicateBundle()) { // detect duplicated bundle
470
523
  $.tooling.log('Bundle manifest have error that found duplicated bundles', $.tooling.LogTypes.Error);
471
524
  reject();
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@omnia/tooling-vue",
3
3
  "license": "MIT",
4
- "version": "8.0.332-dev",
4
+ "version": "8.0.334-dev",
5
5
  "description": "Used to bundle and serve manifests web component that build on Vue framework.",
6
6
  "scripts": {
7
7
  "test": "echo \"Error: no test specified\" && exit 1"
@@ -19,8 +19,8 @@
19
19
  ],
20
20
  "author": "Precio Fishbone",
21
21
  "dependencies": {
22
- "@omnia/fx-models": "8.0.332-dev",
23
- "@omnia/tooling-composers": "8.0.332-dev",
22
+ "@omnia/fx-models": "8.0.334-dev",
23
+ "@omnia/tooling-composers": "8.0.334-dev",
24
24
  "@types/mousetrap": "1.5.34",
25
25
  "@types/quill": "1.3.6",
26
26
  "@types/zepto": "1.0.29",