Package Exports
- co-logger
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (co-logger) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
co-logger
Winston based logger for compound.js
Replace default CompoundJS logger with Winston
Installation
Step 1. install using npm:
npm install co-logger --saveStep 2. add co-logger to config/autoload.js, for example:
module.exports = function (compound) {
return [
'ejs-ext',
'jugglingdb',
'seedjs',
'co-logger'
].map(require);
};Usages
You can use co-logger with old way:
compound.logger.write("My log message")Or:
log = require("co-logger");
log.debug("My log message");
log.error("My log message with error", err);Or:
compound.logger.warn("My log message");