infront-logger 1.0.7 → 1.0.9

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/dist/index.es.js CHANGED
@@ -63,7 +63,7 @@ function fileFormatter(options) {
63
63
  );
64
64
  }
65
65
  function consoleFormatter(options) {
66
- return format$1.combine(
66
+ let formatters = [
67
67
  format$1.errors({ stack: true }),
68
68
  format$1.printf((info) => {
69
69
  if ((info == null ? void 0 : info.level) === "error" && info.stack) {
@@ -73,9 +73,12 @@ function consoleFormatter(options) {
73
73
  }
74
74
  }),
75
75
  // options.consoleJSON? format.json() : {transform : (info)=>info},
76
- options.consoleJSON ? format$1.json() : format$1.splat(),
77
- format$1.colorize({ all: true })
78
- );
76
+ options.consoleJSON ? format$1.json() : format$1.splat()
77
+ ];
78
+ if (!options.consoleJSON) {
79
+ formatters.push(format$1.colorize({ all: true }));
80
+ }
81
+ return format$1.combine(...formatters);
79
82
  }
80
83
  function getFormatter(type, options) {
81
84
  switch (type) {
package/dist/index.umd.js CHANGED
@@ -67,7 +67,7 @@
67
67
  );
68
68
  }
69
69
  function consoleFormatter(options) {
70
- return format$1.combine(
70
+ let formatters = [
71
71
  format$1.errors({ stack: true }),
72
72
  format$1.printf((info) => {
73
73
  if ((info == null ? void 0 : info.level) === "error" && info.stack) {
@@ -77,9 +77,12 @@
77
77
  }
78
78
  }),
79
79
  // options.consoleJSON? format.json() : {transform : (info)=>info},
80
- options.consoleJSON ? format$1.json() : format$1.splat(),
81
- format$1.colorize({ all: true })
82
- );
80
+ options.consoleJSON ? format$1.json() : format$1.splat()
81
+ ];
82
+ if (!options.consoleJSON) {
83
+ formatters.push(format$1.colorize({ all: true }));
84
+ }
85
+ return format$1.combine(...formatters);
83
86
  }
84
87
  function getFormatter(type, options) {
85
88
  switch (type) {
package/package.json CHANGED
@@ -1,14 +1,13 @@
1
1
  {
2
2
  "name": "infront-logger",
3
- "version": "1.0.7",
3
+ "version": "1.0.9",
4
4
  "description": "",
5
5
  "files": [
6
- "dist",
7
- "lib/main.d.ts"
6
+ "dist"
8
7
  ],
9
8
  "main": "./dist/index.umd.js",
10
9
  "module": "./dist/index.es.js",
11
- "types": "lib/main.d.ts",
10
+ "types": "dist/main.d.ts",
12
11
  "exports": {
13
12
  ".": {
14
13
  "import": "./dist/index.es.js",
@@ -21,6 +20,7 @@
21
20
  "devDependencies": {
22
21
  "@esbuild-plugins/node-globals-polyfill": "^0.2.3",
23
22
  "@esbuild-plugins/node-modules-polyfill": "^0.2.2",
23
+ "rollup-plugin-copy": "^3.5.0",
24
24
  "vite": "^5.0.12"
25
25
  },
26
26
  "dependencies": {
File without changes