@node-ts/logger-core
Advanced tools
Comparing version 0.0.6 to 0.0.8
@@ -10,2 +10,6 @@ "use strict"; | ||
bind(logger_symbols_1.LOGGER_SYMBOLS.LoggerFactory).to(console_logger_factory_1.ConsoleLoggerFactory); | ||
bind(logger_symbols_1.LOGGER_SYMBOLS.Logger).toDynamicValue(context => { | ||
const factory = context.container.get(logger_symbols_1.LOGGER_SYMBOLS.LoggerFactory); | ||
return factory.build('Application', context.container); | ||
}); | ||
}); | ||
@@ -12,0 +16,0 @@ } |
{ | ||
"name": "@node-ts/logger-core", | ||
"version": "0.0.6", | ||
"version": "0.0.8", | ||
"description": "Defines a logging adapter contract between consumers and implementations", | ||
@@ -35,3 +35,4 @@ "main": "./dist/index.js", | ||
"inversify": ">= 5.0.1" | ||
} | ||
}, | ||
"gitHead": "34a883673813755ae9656f946887ab640f676b62" | ||
} |
import { ContainerModule } from 'inversify' | ||
import { LOGGER_SYMBOLS } from './logger-symbols' | ||
import { ConsoleLoggerFactory } from './console-logger-factory' | ||
import { LoggerFactory } from './logger-factory' | ||
@@ -9,4 +10,8 @@ export class LoggerModule extends ContainerModule { | ||
bind(LOGGER_SYMBOLS.LoggerFactory).to(ConsoleLoggerFactory) | ||
bind(LOGGER_SYMBOLS.Logger).toDynamicValue(context => { | ||
const factory = context.container.get<LoggerFactory>(LOGGER_SYMBOLS.LoggerFactory) | ||
return factory.build('Application', context.container) | ||
}) | ||
}) | ||
} | ||
} |
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
27162
423