produce? I have
class Logger {
constructor(level) { this.level = level }
getLevel() { return this.level }
}
class UsesLogger {
constructor(logger) { this.logger = logger } //possibly inject logger
getLogLevel() { return this.logger.level }
}
constructor(logger = new Logger()) {
Обсуждают сегодня