@polylith/builder 0.2.5 → 0.2.6

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.
package/App.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import path from 'node:path';
2
2
  import {readFile, writeFile, stat} from 'node:fs/promises';
3
- import cc from "node-console-colors";
3
+ import cc from "@ondohers/console-colors";
4
4
  import express from 'express';
5
5
  import * as rollup from 'rollup';
6
6
  import { babel } from '@rollup/plugin-babel';
@@ -126,7 +126,7 @@ export default class App {
126
126
  await router(appRouter, this);
127
127
  return true;
128
128
  } catch(e) {
129
- console.error(cc.set('fg_red'), 'error while building router', this.modulePath);
129
+ console.error(cc.set('fg_red;, error while building router'), this.modulePath);
130
130
  console.log(e);
131
131
  }
132
132
  }
@@ -466,7 +466,7 @@ export default class App {
466
466
  let feature = module.default;
467
467
  await feature.build(this);
468
468
  } catch(e) {
469
- console.error(cc.set('fg_red'), 'error while building feature', root);
469
+ console.error(cc.set('fg_red', 'error while building feature'), root);
470
470
  console.log(e);
471
471
  }
472
472
 
@@ -816,15 +816,15 @@ export default class App {
816
816
  }
817
817
 
818
818
  if (event.code === 'ERROR') {
819
- console.error(cc.set('fg_red'), event.error)
819
+ console.error(cc.set('fg_red', event.error))
820
820
  }
821
821
 
822
822
  if (event.code === 'BUNDLE_START') {
823
- console.log(cc.set('fg_blue'), 'building...')
823
+ console.log(cc.set('fg_blue', 'building...'));
824
824
  }
825
825
 
826
826
  if (event.code === 'BUNDLE_END') {
827
- console.log(cc.set('fg_blue'), 'build complete')
827
+ console.log(cc.set('fg_blue', 'build complete'))
828
828
  }
829
829
  }.bind(this));
830
830
  return true;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@polylith/builder",
3
- "version": "0.2.5",
3
+ "version": "0.2.6",
4
4
  "description": "The polylith builder",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -18,6 +18,7 @@
18
18
  "dependencies": {
19
19
  "@babel/preset-env": "^7.16.11",
20
20
  "@babel/preset-react": "^7.16.7",
21
+ "@ondohers/console-colors": "^0.1.0",
21
22
  "@rollup/plugin-babel": "^5.3.0",
22
23
  "@rollup/plugin-commonjs": "^24.0.0",
23
24
  "@rollup/plugin-json": "^5.0.2",
package/plugin-watch.js CHANGED
@@ -1,11 +1,11 @@
1
- import cc from "node-console-colors";
1
+ import cc from "@ondohers/console-colors";
2
2
 
3
3
  export default function watch() {
4
4
  return {
5
5
  name: 'watch-log',
6
6
 
7
7
  watchChange(id, type) {
8
- console.log(`${cc.set('fg_green')}${type.event}${cc.set('reset')} of file ${id}`)
8
+ console.log(`${cc.set('fg_green', type.event)} of file ${id}`)
9
9
  return null;
10
10
  }
11
11
  };