helper('log:get')(name)
name
: must be in <pkgId>:<itemName>
syntax. Required.
The matched winston logger is returned.
helper('log:make')(name, opts)
If a log with that name already exists, then it will be returned immediately. If it doesn't exist yet, a new winston logger is created and returned.
Log file will be saved in your data directory:
/<data dir>
/log
/<pkgId>
<itemName>.log
Log file will also be automatically rotated every day.
name
: must be in <pkgId>:<itemName>
syntax. Required.
opts
: the same winston transport options as in config file. Optional.
Instance of winston logger.