Elsewhere uses a simple logging system that writes to Node’s console. You can replace the logger with your own, for example, to store warnings and errors in a database or log file. To add your own custom logger, all you need to do is provide an object with the following interface:
{
info: function (message) { /* code to pass on message */ },
log: function (message) { /* code to pass on message */ },
warn: function (message) { /* code to pass on message */ },
error: function (message) { /* code to pass on message */ }
}
You must then add this object to the logger property of the options object passed into the graph() method.