@ctx-core/logger
Advanced tools
Comparing version 6.3.1 to 7.0.0
# @ctx-core/logger | ||
## 7.0.0 | ||
### Major Changes | ||
- \$ suffix for stores | ||
- \_ suffix for factory functions | ||
## 6.3.1 | ||
@@ -4,0 +11,0 @@ |
@@ -1,1 +0,1 @@ | ||
export declare function _console(fn: Function, log_ctx: Record<keyof Console, any>): (...arg_a1: any[]) => any; | ||
export declare function _console(fn: Function, log_ctx: Record<keyof Console, any>): (...arg_a: any[]) => any; |
export function _console(fn, log_ctx) { | ||
return (...arg_a1) => { | ||
return (...arg_a) => { | ||
let key; | ||
@@ -7,5 +7,5 @@ for (key in log_ctx) { | ||
} | ||
return fn(...arg_a1); | ||
return fn(...arg_a); | ||
}; | ||
} | ||
//# sourceMappingURL=../src/dist/_console.js.map |
@@ -1,1 +0,1 @@ | ||
export declare function _log(message: any, fn: Function): (...arg_a1: any[]) => any; | ||
export declare function _log(message: any, fn: Function): (...arg_a: any[]) => any; |
import { log } from './log'; | ||
export function _log(message, fn) { | ||
return (...arg_a1) => { | ||
return (...arg_a) => { | ||
log(message); | ||
return fn(...arg_a1); | ||
return fn(...arg_a); | ||
}; | ||
} | ||
//# sourceMappingURL=../src/dist/_log.js.map |
export declare function init_chalk(): void; | ||
export declare function chalk_debug(...arg_a1: any[]): void; | ||
export declare function chalk_log(...arg_a1: any[]): void; | ||
export declare function chalk_info(...arg_a1: any[]): void; | ||
export declare function chalk_warn(...arg_a1: any[]): void; | ||
export declare function chalk_error(...arg_a1: any[]): void; | ||
export declare function chalk_debug(...arg_a: any[]): void; | ||
export declare function chalk_log(...arg_a: any[]): void; | ||
export declare function chalk_info(...arg_a: any[]): void; | ||
export declare function chalk_warn(...arg_a: any[]): void; | ||
export declare function chalk_error(...arg_a: any[]): void; |
@@ -6,41 +6,41 @@ let chalk; | ||
} | ||
export function chalk_debug(...arg_a1) { | ||
return (console.debug || console.info).apply(console, _debug_chalk_a1(...arg_a1)); | ||
export function chalk_debug(...arg_a) { | ||
return (console.debug || console.info).apply(console, _debug_chalk_a1(...arg_a)); | ||
} | ||
export function chalk_log(...arg_a1) { | ||
return console.log.apply(console, _log_chalk_a1(...arg_a1)); | ||
export function chalk_log(...arg_a) { | ||
return console.log.apply(console, _log_chalk_a1(...arg_a)); | ||
} | ||
export function chalk_info(...arg_a1) { | ||
return console.info.apply(console, _info_chalk_a1(...arg_a1)); | ||
export function chalk_info(...arg_a) { | ||
return console.info.apply(console, _info_chalk_a1(...arg_a)); | ||
} | ||
export function chalk_warn(...arg_a1) { | ||
return console.warn.apply(console, _warn_chalk_a1(...arg_a1)); | ||
export function chalk_warn(...arg_a) { | ||
return console.warn.apply(console, _warn_chalk_a1(...arg_a)); | ||
} | ||
export function chalk_error(...arg_a1) { | ||
return console.error.apply(console, _error_chalk_a1(...arg_a1)); | ||
export function chalk_error(...arg_a) { | ||
return console.error.apply(console, _error_chalk_a1(...arg_a)); | ||
} | ||
function _debug_chalk_a1(...arg_a1) { | ||
function _debug_chalk_a1(...arg_a) { | ||
return (use_chalk | ||
? [chalk.white(...arg_a1)] | ||
: arg_a1); | ||
? [chalk.white(...arg_a)] | ||
: arg_a); | ||
} | ||
function _log_chalk_a1(...arg_a1) { | ||
function _log_chalk_a1(...arg_a) { | ||
return (use_chalk | ||
? [chalk.grey(...arg_a1)] | ||
: arg_a1); | ||
? [chalk.grey(...arg_a)] | ||
: arg_a); | ||
} | ||
function _info_chalk_a1(...arg_a1) { | ||
function _info_chalk_a1(...arg_a) { | ||
return (use_chalk | ||
? [chalk.green(...arg_a1)] | ||
: arg_a1); | ||
? [chalk.green(...arg_a)] | ||
: arg_a); | ||
} | ||
function _warn_chalk_a1(...arg_a1) { | ||
function _warn_chalk_a1(...arg_a) { | ||
return (use_chalk | ||
? [chalk.red(...arg_a1)] | ||
: arg_a1); | ||
? [chalk.red(...arg_a)] | ||
: arg_a); | ||
} | ||
function _error_chalk_a1(...arg_a1) { | ||
function _error_chalk_a1(...arg_a) { | ||
return (use_chalk | ||
? [chalk.red.bold(...arg_a1)] | ||
: arg_a1); | ||
? [chalk.red.bold(...arg_a)] | ||
: arg_a); | ||
} | ||
@@ -52,4 +52,4 @@ function _chalk() { | ||
else { | ||
return function chalk(...arg_a1) { | ||
return arg_a1; | ||
return function chalk(...arg_a) { | ||
return arg_a; | ||
}; | ||
@@ -56,0 +56,0 @@ } |
@@ -1,1 +0,1 @@ | ||
export declare function debug(...arg_a1: any[]): void; | ||
export declare function debug(...arg_a: any[]): void; |
import { chalk_debug } from './chalk'; | ||
import { _logger_timestamp } from './_logger_timestamp'; | ||
export function debug(...arg_a1) { | ||
return chalk_debug(_logger_timestamp(), ...arg_a1); | ||
import { logger_timestamp_ } from './logger_timestamp_'; | ||
export function debug(...arg_a) { | ||
return chalk_debug(logger_timestamp_(), ...arg_a); | ||
} | ||
//# sourceMappingURL=../src/dist/debug.js.map |
@@ -1,2 +0,2 @@ | ||
export declare function error(...arg_a1: any[]): void; | ||
export declare function error(...arg_a: any[]): void; | ||
export { error as error__log }; |
import { chalk_error } from './chalk'; | ||
import { _logger_timestamp } from './_logger_timestamp'; | ||
export function error(...arg_a1) { | ||
return chalk_error(_logger_timestamp(), ...arg_a1); | ||
import { logger_timestamp_ } from './logger_timestamp_'; | ||
export function error(...arg_a) { | ||
return chalk_error(logger_timestamp_(), ...arg_a); | ||
} | ||
export { error as error__log }; | ||
//# sourceMappingURL=../src/dist/error.js.map |
@@ -1,4 +0,4 @@ | ||
export * from './_console'; | ||
export * from './_log'; | ||
export * from './_logger_timestamp'; | ||
export * from './console_'; | ||
export * from './log_'; | ||
export * from './logger_timestamp_'; | ||
export * from './chalk'; | ||
@@ -5,0 +5,0 @@ export * from './debug'; |
@@ -1,4 +0,4 @@ | ||
export * from './_console'; | ||
export * from './_log'; | ||
export * from './_logger_timestamp'; | ||
export * from './console_'; | ||
export * from './log_'; | ||
export * from './logger_timestamp_'; | ||
export * from './chalk'; | ||
@@ -5,0 +5,0 @@ export * from './debug'; |
@@ -1,1 +0,1 @@ | ||
export declare function info(...arg_a1: any[]): void; | ||
export declare function info(...arg_a: any[]): void; |
import { chalk_info } from './chalk'; | ||
import { _logger_timestamp } from './_logger_timestamp'; | ||
export function info(...arg_a1) { | ||
return chalk_info(_logger_timestamp(), ...arg_a1); | ||
import { logger_timestamp_ } from './logger_timestamp_'; | ||
export function info(...arg_a) { | ||
return chalk_info(logger_timestamp_(), ...arg_a); | ||
} | ||
//# sourceMappingURL=../src/dist/info.js.map |
@@ -1,1 +0,1 @@ | ||
export declare function log(...arg_a1: any[]): void; | ||
export declare function log(...arg_a: any[]): void; |
import { chalk_log } from './chalk'; | ||
import { _logger_timestamp } from './_logger_timestamp'; | ||
export function log(...arg_a1) { | ||
return chalk_log(_logger_timestamp(), ...arg_a1); | ||
import { logger_timestamp_ } from './logger_timestamp_'; | ||
export function log(...arg_a) { | ||
return chalk_log(logger_timestamp_(), ...arg_a); | ||
} | ||
//# sourceMappingURL=../src/dist/log.js.map |
@@ -1,1 +0,1 @@ | ||
export declare function warn(...arg_a1: any[]): void; | ||
export declare function warn(...arg_a: any[]): void; |
import { chalk_warn } from './chalk'; | ||
import { _logger_timestamp } from './_logger_timestamp'; | ||
export function warn(...arg_a1) { | ||
return chalk_warn(_logger_timestamp(), ...arg_a1); | ||
import { logger_timestamp_ } from './logger_timestamp_'; | ||
export function warn(...arg_a) { | ||
return chalk_warn(logger_timestamp_(), ...arg_a); | ||
} | ||
//# sourceMappingURL=../src/dist/warn.js.map |
{ | ||
"name": "@ctx-core/logger", | ||
"version": "6.3.1", | ||
"version": "7.0.0", | ||
"description": "ctx-core logger", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -9,50 +9,50 @@ import type { Chalk } from 'chalk' | ||
} | ||
export function chalk_debug(...arg_a1:any[]) { | ||
return (console.debug || console.info).apply(console, _debug_chalk_a1(...arg_a1)) | ||
export function chalk_debug(...arg_a:any[]) { | ||
return (console.debug || console.info).apply(console, _debug_chalk_a1(...arg_a)) | ||
} | ||
export function chalk_log(...arg_a1:any[]) { | ||
return console.log.apply(console, _log_chalk_a1(...arg_a1)) | ||
export function chalk_log(...arg_a:any[]) { | ||
return console.log.apply(console, _log_chalk_a1(...arg_a)) | ||
} | ||
export function chalk_info(...arg_a1:any[]) { | ||
return console.info.apply(console, _info_chalk_a1(...arg_a1)) | ||
export function chalk_info(...arg_a:any[]) { | ||
return console.info.apply(console, _info_chalk_a1(...arg_a)) | ||
} | ||
export function chalk_warn(...arg_a1:any[]) { | ||
return console.warn.apply(console, _warn_chalk_a1(...arg_a1)) | ||
export function chalk_warn(...arg_a:any[]) { | ||
return console.warn.apply(console, _warn_chalk_a1(...arg_a)) | ||
} | ||
export function chalk_error(...arg_a1:any[]) { | ||
return console.error.apply(console, _error_chalk_a1(...arg_a1)) | ||
export function chalk_error(...arg_a:any[]) { | ||
return console.error.apply(console, _error_chalk_a1(...arg_a)) | ||
} | ||
function _debug_chalk_a1(...arg_a1:any[]) { | ||
function _debug_chalk_a1(...arg_a:any[]) { | ||
return ( | ||
use_chalk | ||
? [chalk.white(...arg_a1)] | ||
: arg_a1 | ||
? [chalk.white(...arg_a)] | ||
: arg_a | ||
) | ||
} | ||
function _log_chalk_a1(...arg_a1:any[]) { | ||
function _log_chalk_a1(...arg_a:any[]) { | ||
return ( | ||
use_chalk | ||
? [chalk.grey(...arg_a1)] | ||
: arg_a1 | ||
? [chalk.grey(...arg_a)] | ||
: arg_a | ||
) | ||
} | ||
function _info_chalk_a1(...arg_a1:any[]) { | ||
function _info_chalk_a1(...arg_a:any[]) { | ||
return ( | ||
use_chalk | ||
? [chalk.green(...arg_a1)] | ||
: arg_a1 | ||
? [chalk.green(...arg_a)] | ||
: arg_a | ||
) | ||
} | ||
function _warn_chalk_a1(...arg_a1:any[]) { | ||
function _warn_chalk_a1(...arg_a:any[]) { | ||
return ( | ||
use_chalk | ||
? [chalk.red(...arg_a1)] | ||
: arg_a1 | ||
? [chalk.red(...arg_a)] | ||
: arg_a | ||
) | ||
} | ||
function _error_chalk_a1(...arg_a1:any[]) { | ||
function _error_chalk_a1(...arg_a:any[]) { | ||
return ( | ||
use_chalk | ||
? [chalk.red.bold(...arg_a1)] | ||
: arg_a1 | ||
? [chalk.red.bold(...arg_a)] | ||
: arg_a | ||
) | ||
@@ -64,6 +64,6 @@ } | ||
} else { | ||
return function chalk(...arg_a1:any[]) { | ||
return arg_a1 | ||
return function chalk(...arg_a:any[]) { | ||
return arg_a | ||
} | ||
} | ||
} |
import { chalk_debug } from './chalk' | ||
import { _logger_timestamp } from './_logger_timestamp' | ||
export function debug(...arg_a1: any[]) { | ||
return chalk_debug(_logger_timestamp(), ...arg_a1) | ||
import { logger_timestamp_ } from './logger_timestamp_' | ||
export function debug(...arg_a: any[]) { | ||
return chalk_debug(logger_timestamp_(), ...arg_a) | ||
} |
import { chalk_error } from './chalk' | ||
import { _logger_timestamp } from './_logger_timestamp' | ||
export function error(...arg_a1: any[]) { | ||
return chalk_error(_logger_timestamp(), ...arg_a1) | ||
import { logger_timestamp_ } from './logger_timestamp_' | ||
export function error(...arg_a: any[]) { | ||
return chalk_error(logger_timestamp_(), ...arg_a) | ||
} | ||
@@ -6,0 +6,0 @@ export { |
@@ -1,4 +0,4 @@ | ||
export * from './_console' | ||
export * from './_log' | ||
export * from './_logger_timestamp' | ||
export * from './console_' | ||
export * from './log_' | ||
export * from './logger_timestamp_' | ||
export * from './chalk' | ||
@@ -5,0 +5,0 @@ export * from './debug' |
import { chalk_info } from './chalk' | ||
import { _logger_timestamp } from './_logger_timestamp' | ||
export function info(...arg_a1: any[]) { | ||
return chalk_info(_logger_timestamp(), ...arg_a1) | ||
import { logger_timestamp_ } from './logger_timestamp_' | ||
export function info(...arg_a: any[]) { | ||
return chalk_info(logger_timestamp_(), ...arg_a) | ||
} |
import { chalk_log } from './chalk' | ||
import { _logger_timestamp } from './_logger_timestamp' | ||
export function log(...arg_a1: any[]) { | ||
return chalk_log(_logger_timestamp(), ...arg_a1) | ||
import { logger_timestamp_ } from './logger_timestamp_' | ||
export function log(...arg_a: any[]) { | ||
return chalk_log(logger_timestamp_(), ...arg_a) | ||
} |
import { chalk_warn } from './chalk' | ||
import { _logger_timestamp } from './_logger_timestamp' | ||
export function warn(...arg_a1: any[]) { | ||
return chalk_warn(_logger_timestamp(), ...arg_a1) | ||
import { logger_timestamp_ } from './logger_timestamp_' | ||
export function warn(...arg_a: any[]) { | ||
return chalk_warn(logger_timestamp_(), ...arg_a) | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
18526
54
333