{"name":"abstract-logging","version":"2.0.0","description":"A noop logger that conforms to the Log4j interface for modules to stub out internal logging","main":"index.js","scripts":{"test":"node test.js"},"repository":{"type":"git","url":"git+https://github.com/jsumners/abstract-logging.git"},"keywords":["log","logging","logger","pino"],"author":{"name":"James Sumners","email":"james.sumners@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/jsumners/abstract-logging/issues"},"homepage":"https://github.com/jsumners/abstract-logging#readme","gitHead":"a8c0a0a4540d49fd59c71d992c86d98271d7a753","_id":"abstract-logging@2.0.0","_npmVersion":"6.4.1","_nodeVersion":"10.15.3","_npmUser":{"name":"jsumners","email":"james.sumners@gmail.com"},"dist":{"integrity":"sha512-/oA9z7JszpIioo6J6dB79LVUgJ3eD3cxkAmdCkvWWS+Y9tPtALs1rLqOekLUXUbYqM2fB9TTK0ibAyZJJOP/CA==","shasum":"08a85814946c98ef06f4256ad470aba1886d4490","tarball":"http://registry-npm.ywwl.com/abstract-logging/download/abstract-logging-2.0.0.tgz","fileCount":4,"unpackedSize":1958,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdzJbuCRA9TVsSAnZWagAA03gP/jnQSYVX21aCOFJtGHny\nuJ0bDdof0EwrMqRyatyXcGdUTmba6+i1jgs0LuLC40mODR1ELq/v5eABlaDu\nXE+SxU/Aq6EMklfeKEXR1hn4j12DoAtfIDssKoQk59wqhp475EE/jm0fAmNG\nVfE+TKDi4c9nC6tCrYZ8r5GHSRYu/Xdn4HokLFoXww2/EO2YOYUh/svE+iEr\nzQwPIcWeG6OpxrV5jZ5RJzG/gSRDdXmElMO06E9/8bO/xS6Dwdl7h/wmP1tL\n4xn7XTIQdj/QiRpF+kifXxlrCUPM7x1Sd43/dbOuNSwF2ZqqUO/gtRvg/gUS\nOiEWJMxDCM5N8QvHp/0hgo2NW4UXINU7UY8aDC48frZNPCr5y5QxALPryu9n\nhrttYXMDsYPIn5REu69cfBVlOaIQy/AvHdJ0fG1ubOZ+6gzghcfbxqRy7WJ1\nVnmxc3K3JS8QUB3G8jjf0Ao0mNKZGGnLDvd6YHP0DJR0RcAiCzR/ou1JiFYb\n+1e+Z6QMvEXn4D/OuucMHC1Qby8jVo4OUBzkqqGeF2dMZbGCcfFqTq8jTp1Z\ncnODtivGz4QYdpjmZud9wmIx5T5HtVTcIvOZvIlZ1FPhhP5DldJQtPbEIqO1\n7AhczWf21fuAMQuycbwKa01E71rwuehx22imHbFNEtiaLq9vJE18juPd06z4\nFJ5t\r\n=7mr4\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCT+gEjo9tMmjRZqbd2901sQqeYLbkogQrDEhcCH7tQnAIgJn3apzN9YRlsK/O4R8pQh6WaQtFLeUOVZl52+dLoAz8="}],"size":1083,"noattachment":false,"key":"/abstract-logging/-/abstract-logging-2.0.0.tgz"},"maintainers":[{"name":"jsumners","email":"james.sumners@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/abstract-logging_2.0.0_1573689070544_0.9593485003396589"},"_hasShrinkwrap":false,"readme":"# abstract-logging\n\nThis module provides an interface for modules to include so that they can\nsupport logging via an external logger that conforms to the standard Log4j\ninterface. One such logger is [Pino](https://npm.im/pino). This module\nis intended for modules that are meant to be used by other modules.\n\nExample:\n\n```js\n'use strict'\n\nfunction AwesomeLibrary (options) {\n  this.log = (options.logger) ? options.logger : require('abstract-logging')\n}\n\nAwesomeLibrary.prototype.coolMethod = function () {\n  this.log.trace('AwesomeLibrary.coolMethod was invoked')\n  return {}\n}\n\nmodule.exports = AwesomeLibrary\n```\n\n## Interface\n\nAvailable methods:\n\n+ `fatal`\n+ `error`\n+ `warn`\n+ `info`\n+ `debug`\n+ `trace`\n\nAll methods are no operation functions.\n\nSome loggers, like [Pino](https://getpino.io/), implement a `child()` method. This method can be easily added to an `abstract-logging` instance when stubbing out such loggers:\n\n```js\nconst logger = require('abstract-logging')\nlogger.child = () => logger\n```\n\n## License\n\n[MIT License](http://jsumners.mit-license.org/)\n","publish_time":1573689070640,"_cnpm_publish_time":1573689070640,"dist-tags":{"latest":"2.0.1"}}