@kitql/helpers
Advanced tools
Comparing version 0.8.8 to 0.8.9
# @kitql/helpers | ||
## 0.8.9 | ||
### Patch Changes | ||
- [#629](https://github.com/jycouet/kitql/pull/629) [`f474d6f`](https://github.com/jycouet/kitql/commit/f474d6f7b4a1aefefb5eed9dce98bec226ea0310) Thanks [@jycouet](https://github.com/jycouet)! - bump internals | ||
## 0.8.8 | ||
@@ -4,0 +10,0 @@ |
@@ -76,3 +76,3 @@ "use strict"; | ||
module.exports = __toCommonJS(colors_exports); | ||
var import_constants = require("../constants.js"); | ||
var import_esm_env = require("esm-env"); | ||
var stylesBrowser = __toESM(require("./stylesBrowser.js"), 1); | ||
@@ -87,3 +87,3 @@ var stylesNode = __toESM(require("./stylesNode.js"), 1); | ||
const color = (style, str) => { | ||
return import_constants.BROWSER ? colorBrowser(style, str) : colorNode(style, str); | ||
return import_esm_env.BROWSER ? colorBrowser(style, str) : colorNode(style, str); | ||
}; | ||
@@ -121,3 +121,3 @@ const colorNode = (style, str) => { | ||
const colorProcess = (...msgs) => { | ||
if (!import_constants.BROWSER) { | ||
if (!import_esm_env.BROWSER) { | ||
return [...msgs]; | ||
@@ -124,0 +124,0 @@ } |
@@ -1,2 +0,2 @@ | ||
import { BROWSER } from '../constants.js'; | ||
import { BROWSER } from 'esm-env'; | ||
import * as stylesBrowser from './stylesBrowser.js'; | ||
@@ -3,0 +3,0 @@ import * as stylesNode from './stylesNode.js'; |
@@ -1,2 +0,2 @@ | ||
import { bold, colorProcess, greenBright, redBright, bgRedBright, bgGreen, bgBlueBright, } from './colors/index.js'; | ||
import { bgBlueBright, bgGreen, bgRedBright, bold, colorProcess, greenBright, redBright, } from './colors/index.js'; | ||
export class Log { | ||
@@ -49,5 +49,5 @@ toolName; | ||
if (table.length === 0 || (table.length === 1 && table[0] === '')) { | ||
return colorProcess(...[...msgs.flatMap(c => c)]); | ||
return colorProcess(...[...msgs.flatMap((c) => c)]); | ||
} | ||
return colorProcess(...[table.join(''), ...msgs.flatMap(c => c)]); | ||
return colorProcess(...[table.join(''), ...msgs.flatMap((c) => c)]); | ||
} | ||
@@ -60,3 +60,3 @@ /** | ||
const built = this.buildStr(false, false, conf.level, ...msgs); | ||
console.info(...built.flatMap(c => c)); | ||
console.info(...built.flatMap((c) => c)); | ||
return built; | ||
@@ -69,3 +69,3 @@ } | ||
const built = this.buildStr(false, false, 0, ...msgs); | ||
console.info(...built.flatMap(c => c)); | ||
console.info(...built.flatMap((c) => c)); | ||
return built; | ||
@@ -79,3 +79,3 @@ } | ||
const built = this.buildStr(false, true, conf.level, msgs); | ||
console.info(...built.flatMap(c => c)); | ||
console.info(...built.flatMap((c) => c)); | ||
return built; | ||
@@ -88,3 +88,3 @@ } | ||
const built = this.buildStr(false, true, 0, msgs); | ||
console.info(...built.flatMap(c => c)); | ||
console.info(...built.flatMap((c) => c)); | ||
return built; | ||
@@ -98,5 +98,5 @@ } | ||
// Keep error to have the stacktrace in the browser | ||
console.error(...built.flatMap(c => c)); | ||
console.error(...built.flatMap((c) => c)); | ||
return built; | ||
} | ||
} |
@@ -5,3 +5,3 @@ export async function sleep(ms) { | ||
} | ||
return new Promise(resolve => setTimeout(resolve, ms)); | ||
return new Promise((resolve) => setTimeout(resolve, ms)); | ||
} |
@@ -122,3 +122,3 @@ /** | ||
if (value) { | ||
return value => { | ||
return (value) => { | ||
let message = `Object can not safely be stringified. Received type ${typeof value}`; | ||
@@ -125,0 +125,0 @@ if (typeof value !== 'function') |
@@ -12,3 +12,3 @@ { | ||
], | ||
"version": "0.8.8", | ||
"version": "0.8.9", | ||
"license": "MIT", | ||
@@ -22,2 +22,5 @@ "type": "module", | ||
}, | ||
"dependencies": { | ||
"esm-env": "^1.0.0" | ||
}, | ||
"sideEffects": false, | ||
@@ -24,0 +27,0 @@ "svelte": "./esm/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
107004
1
35
2559
+ Addedesm-env@^1.0.0
+ Addedesm-env@1.2.1(transitive)