{"name":"deprecation","version":"1.0.1","description":"Log a deprecation message with stack","main":"index.js","scripts":{"test":"node test.js"},"keywords":["deprecate","deprecated","deprecation"],"author":{"name":"Gregor Martynus"},"license":"ISC","repository":{"type":"git","url":"git+https://github.com/gr2m/deprecation.git"},"devDependencies":{"semantic-release":"^15.13.3"},"gitHead":"67b5c8c7c98cf99fa18c63dc4d7f79b0aa5815bd","bugs":{"url":"https://github.com/gr2m/deprecation/issues"},"homepage":"https://github.com/gr2m/deprecation#readme","_id":"deprecation@1.0.1","_npmVersion":"6.5.0","_nodeVersion":"10.15.2","_npmUser":{"name":"gr2m","email":"gregor@martynus.net"},"dist":{"integrity":"sha512-ccVHpE72+tcIKaGMql33x5MAjKQIZrk+3x2GbJ7TeraUCZWHoT+KSZpoC+JQFsUBlSTXUrBaGiF0j6zVTepPLg==","shasum":"2df79b79005752180816b7b6e079cbd80490d711","tarball":"http://registry-npm.ywwl.com/deprecation/download/deprecation-1.0.1.tgz","fileCount":6,"unpackedSize":3649,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcf19YCRA9TVsSAnZWagAABzwP/i+emgK/OHOzXvz1nCxT\njx6iD4TLOtNe+TFT+Yybaut6j8vtmLPWY+OH5v9VMb+gko9fTY3MsPhFl87l\nxiBvA+FrwyQJKQHAkuRFxlb91aRqGBgUqgNalyOrMo1adqozQEuLK4l52Dyw\n/LvfwfQMrrYuOzv3C9gfquET63ZFAEWEaIMCrGCNJlA8zSSYurNpg5KyDDnu\nObVPKQUOS786M5eiTuBM2T2COhSUcmqzjdgUITZNTax7TnIoCpHlrHmV0mEs\nUqk/6ZJ3emvqm/xAHz33zokL3n5mznh6D2KkR7/U1fbNfQ3+70VFWvYKoTz7\nwKwKY1s+6AWRzNX0vGFbT/Qoy/8t/XTNIqi/uMHVRpuc+wrkWywA+ZDwu4gO\nl8x1DK0qVWhZjaWZiuqVCHKaGiCrxI5Js/N1FqemfQB8/UmtP85OhG9UXrZz\nVwi9lupZhUBOskvYUFbHW/svYRyeIKN9FSxBuhpwj81V/odwa46XEQoKYRCI\nryC4eXX4TPrLIzk1bWaNmgQAASrOZp2tt9vVYYuV5K46o2Rdga/BAP4q8Kx7\nma7H/WZyDsWg35eHQEyt8suRWd9ogdhs3mVNl2B4Sw3PuFCkbdTMsF9kr0/m\nWD5NRr/kR+hxIqMURJ2grEha6TMRqxuo424uR1kmLUAhaHMGOztOYISiO86+\nKbBa\r\n=JFYR\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDnyzHXdZqD346t+Q5tR9Fyn3/uylUoEh87d1aUgjGrkwIgcUYCYskLZeyA53ka8o2/LSCqLxMUIxmnWWG5j2mBDJA="}],"size":1804,"noattachment":false,"key":"/deprecation/-/deprecation-1.0.1.tgz"},"maintainers":[{"name":"gr2m","email":"gregor@martynus.net"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/deprecation_1.0.1_1551851352031_0.8364341825561346"},"_hasShrinkwrap":false,"readme":"# deprecation\n\n> Log a deprecation message with stack\n\n![build](https://action-badges.now.sh/gr2m/deprecation)\n\n## Usage\n\n<table>\n<tbody valign=top align=left>\n<tr><th>\nBrowsers\n</th><td width=100%>\n\nLoad `deprecation` directly from [cdn.pika.dev](https://cdn.pika.dev)\n\n```html\n<script type=\"module\">\n  import { Deprecation } from \"https://cdn.pika.dev/deprecation/v2\";\n</script>\n```\n\n</td></tr>\n<tr><th>\nNode\n</th><td>\n\nInstall with `npm install deprecation`\n\n```js\nconst { Deprecation } = require(\"deprecation\");\n// or: import { Deprecation } from \"deprecation\";\n```\n\n</td></tr>\n</tbody>\n</table>\n\n```js\nfunction foo() {\n  bar();\n}\n\nfunction bar() {\n  baz();\n}\n\nfunction baz() {\n  console.warn(new Deprecation(\"[my-lib] foo() is deprecated, use bar()\"));\n}\n\nfoo();\n// { Deprecation: [my-lib] foo() is deprecated, use bar()\n//     at baz (/path/to/file.js:12:15)\n//     at bar (/path/to/file.js:8:3)\n//     at foo (/path/to/file.js:4:3)\n```\n\nTo log a deprecation message only once, you can use the [once](https://www.npmjs.com/package/once) module.\n\n```js\nconst Deprecation = require(\"deprecation\");\nconst once = require(\"once\");\n\nconst deprecateFoo = once(console.warn);\n\nfunction foo() {\n  deprecateFoo(new Deprecation(\"[my-lib] foo() is deprecated, use bar()\"));\n}\n\nfoo();\nfoo(); // logs nothing\n```\n\n## License\n\n[ISC](LICENSE)\n","publish_time":1551851352161,"_cnpm_publish_time":1551851352161,"dist-tags":{"latest":"2.3.1"}}