-
Notifications
You must be signed in to change notification settings - Fork 10
Open
Labels
Description
At the moment, logging is done via the context. To increase compatibility with the upcoming node-task, logging could be done via an emitter like so:
this.emitter.emit('log', 'hello');
this.emitter.emit('log.info', 'hello info');
this.emitter.emit('log.warn', 'hello warn');
this.emitter.emit('log.success', 'hello success');
this.emitter.emit('log.error', 'hello error');
this.emitter.emit('log.debug', 'hello debug');Question: Should we remove the ln versions or do it like this:
this.emitter.emit('logln', 'hello');
this.emitter.emit('logln.info', 'hello info');
this.emitter.emit('logln.warn', 'hello warn');
this.emitter.emit('logln.success', 'hello success');
this.emitter.emit('logln.error', 'hello error');
this.emitter.emit('logln.debug', 'hello debug');Please note that, the context parameter could be removed completely. Functions would only receive opts and next.
Reactions are currently unavailable