Comparing version 0.0.0 to 0.0.1
@@ -69,4 +69,3 @@ "use strict"; | ||
cfg = JSON.parse(fs.readFileSync(file).toString()); | ||
baseDir = path_1.parse(file).dir; | ||
console.log("base dir", baseDir); | ||
console.log("Using config file ", file); | ||
} | ||
@@ -73,0 +72,0 @@ catch (e) { |
"use strict"; | ||
exports.__esModule = true; | ||
var index_1 = require("./index"); | ||
var _a = index_1["default"]("test"), debug = _a.debug, error = _a.error, info = _a.info, warn = _a.warn; | ||
debug("test"); | ||
error("test"); | ||
info("test"); | ||
warn("test"); | ||
const { debug } = require("./index")("test.test") | ||
debug("ddddddd") |
import { LoggerFn } from "./types"; | ||
export default function logger(name: string): { | ||
debug: LoggerFn; | ||
info: LoggerFn; | ||
error: LoggerFn; | ||
warn: LoggerFn; | ||
}; | ||
export interface ILoggerCreator { | ||
(name: string): { | ||
debug: LoggerFn; | ||
info: LoggerFn; | ||
error: LoggerFn; | ||
warn: LoggerFn; | ||
}; | ||
logger: ILoggerCreator; | ||
} | ||
export declare const logger: ILoggerCreator; |
@@ -23,7 +23,6 @@ "use strict"; | ||
var namespace = {}; | ||
function logger(name) { | ||
function loggerCreator(name) { | ||
if (configedLogger === null) { | ||
configedLogger = config_1.configure(); | ||
} | ||
console.log(configedLogger); | ||
var colored = ""; | ||
@@ -53,2 +52,4 @@ if (!(name in namespace)) { | ||
} | ||
exports["default"] = logger; | ||
exports.logger = loggerCreator; | ||
exports.logger.logger = exports.logger; | ||
exports = module.exports = exports.logger; |
{ | ||
"name": "b-logger", | ||
"version": "0.0.0", | ||
"version": "0.0.1", | ||
"description": "logger", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
10277
205