{"name":"babel-plugin-array-includes","version":"1.1.1","description":"Replaces `arr.includes(val)' with `arr.indexOf(val) >= 0`.","author":{"name":"Christoph Hermann"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/stoeffel/babel-plugin-array-includes.git"},"peerDependencies":{"babel-core":">=5.2.0"},"main":"lib/index.js","devDependencies":{"babel":"^5.6.0"},"scripts":{"build":"babel-plugin build","push":"babel-plugin publish","test":"babel-plugin test"},"keywords":["babel","babel-plugin","array","includes","polyfill"],"gitHead":"3e9e3d967e8b4a4b4756e8d6c3575d42ace1f2ee","bugs":{"url":"https://github.com/stoeffel/babel-plugin-array-includes/issues"},"homepage":"https://github.com/stoeffel/babel-plugin-array-includes#readme","_id":"babel-plugin-array-includes@1.1.1","_shasum":"6d51e2391c32989395d9b89a8a04fc75419405cc","_from":".","_npmVersion":"2.10.1","_nodeVersion":"0.12.4","_npmUser":{"name":"schtoeffel","email":"schtoeffel@gmail.com"},"maintainers":[{"name":"schtoeffel","email":"schtoeffel@gmail.com"}],"dist":{"shasum":"6d51e2391c32989395d9b89a8a04fc75419405cc","tarball":"http://registry-npm.ywwl.com/babel-plugin-array-includes/download/babel-plugin-array-includes-1.1.1.tgz","integrity":"sha512-bPvmOdoZhtQQaL7dFNI8widMdmrvxFSAqeNHAGm6Gyky61jdtxSp7sAEOV++5ck7HyLdp81AuHc7u5kvpILlGQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCMLuhwXyyxxURUpIFYm7LCz0laqZtkK/D890vF1sXa1wIhALXT76jkZ13SFyEvYZda+oxT0hhJd0sK4RW2Kk5PZJvY"}],"size":1964,"noattachment":false,"key":"/babel-plugin-array-includes/-/babel-plugin-array-includes-1.1.1.tgz"},"directories":{},"readme":"# babel-plugin-array-includes\n\n> Replaces `arr.includes(val)` with `arr.indexOf(val) >= 0`.\n\nThanks to [@sebmck](https://github.com/sebmck) for the help.\n\n## Example\n\n**In**\n\n```javascript\n[1, 2, 3, 5, 8, 13].includes(4);\n```\n\n**Out**\n\n```javascript\n\"use strict\";\n\n[1, 2, 3, 5, 8, 13].indexOf(4) >= 0;\n```\n\n## Pitfalls\n\nThis doesn't work:\n\n**In**\n\n```js\nfunction foo(arr) {\n  return arr.includes('foo');\n}\n```\n\n**Out**\n\n```js\nfunction foo(arr) {\n  return arr.includes('foo'); // still includes\n}\n```\n\n## Installation\n\n```sh\n$ npm install babel-plugin-array-includes\n```\n\n## Usage\n\n### Via `.babelrc` (Recommended)\n\n**.babelrc**\n\n```json\n{\n  \"plugins\": [\"array-includes\"]\n}\n```\n\n### Via CLI\n\n```sh\n$ babel --plugins array-includes script.js\n```\n\n### Via Node API\n\n```javascript\nrequire(\"babel-core\").transform(\"code\", {\n  plugins: [\"array-includes\"]\n});\n```\n","publish_time":1435162046673,"_cnpm_publish_time":1435162046673,"dist-tags":{"latest":"2.0.3"}}