flatiron/winston — Issue #111: Add more (private) methods to transports
Author: paulmillr
Created: 2012-03-07 12:55:46+00:00
State: open

I want to subclass `ConsoleLogger` and add growl functionality if any error had occurred. But I can't do it properly because `ConsoleLogger` uses `common.log` which users don't have access to. Ideally this should look like this etc

```coffeescript
class ConsoleGrowlTransport extends winston.transports.Console
log: (level, msg, meta, callback) ->
return callback null, true if @silent
# @_log instead of common.log
output = @_log
colorize: @colorize
json: @json
level: level
message: msg
meta: meta
stringify: @stringify
timestamp: @timestamp
if level is 'error' or level is 'debug'
util.error output
else
util.puts output
if level is 'error'
growl msg, title: 'Brunch error', =>
@emit 'logged'
callback null, true
```