{"name":"@putout/plugin-convert-for-each-to-for-of","version":"3.0.0","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"putout plugin adds ability to convert forEach to for-of","homepage":"http://github.com/coderaiser/putout","main":"lib/convert-for-each-to-for-of.js","release":false,"tag":false,"changelog":false,"repository":{"type":"git","url":"git://github.com/coderaiser/putout.git"},"scripts":{"test":"madrun test","lint":"madrun lint","fix:lint":"madrun fix:lint","coverage":"madrun coverage"},"dependencies":{},"keywords":["putout","putout-plugin","plugin","remove","only"],"devDependencies":{"@putout/eslint-config":"^1.0.2","@putout/test":"^1.13.0","coveralls":"^3.0.0","eslint":"^6.2.0","eslint-plugin-node":"^10.0.0","eslint-plugin-putout":"^2.0.0","madrun":"^4.1.0","nyc":"^14.0.0","supertape":"^1.0.3"},"peerDependencies":{"putout":">=7"},"license":"MIT","engines":{"node":">=8.3.0"},"publishConfig":{"access":"public"},"bugs":{"url":"https://github.com/coderaiser/putout/issues"},"_id":"@putout/plugin-convert-for-each-to-for-of@3.0.0","_nodeVersion":"13.1.0","_npmVersion":"6.12.1","dist":{"integrity":"sha512-eqVdPSna4CWKOknkYz9kofoRsFfYutbSIsP/CeIrlVn+bTCnsKCd2me5Dg3GKb/U0REQexjXIVwnwp1cwgTwSg==","shasum":"05f39f6512dc1d0269e54b780e46520b1f9b394e","tarball":"http://registry-npm.ywwl.com/@putout/plugin-convert-for-each-to-for-of/download/@putout/plugin-convert-for-each-to-for-of-3.0.0.tgz","fileCount":4,"unpackedSize":6681,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdwtp5CRA9TVsSAnZWagAAF2oP/3BWJgomwI+r8r1mBiXH\nAgEHGSBPPQefI7keix2TZ/ZS9p+2UaxDuDgToh5Imuo0exLkHwsrZ+fdGh/F\nhjljGL2pAkR8eszki4Hgwu0S0wUnAf3wcoy6Dk/lW7v3JdUBjKBYfwV/pkCO\n8vUErAFzYjJRp/G3Ond7PaJ5o4bPf5eY0ItGGJ3lqxKtiUw/pIlPp6cGiU9m\nokjCkBM9AGrgqXLDqLmjLABgbIhBW6qEhUdTYBTEKSAwFMUIR9I7mOfcVkDF\nrLZUxBRRs5IpxL50pZdbRDlRzLVNye+jJu/31vLJ949iRR7mpRiEMAlqJQuN\nEL/m3FPf3ToK0RDIXwf3IougzgccIU+L6EJA0w9UwbWjLZTytL7JNuTpE1wO\nNuc19ceS6kNhCUi8K0W3x15nLyBRlrLOSR2FXs1ektD+EOx2WeiC9U6MYWiN\nGQD7Rf+wmMIDeqPiVrUDFGWcjhiJoB1BjE+3Zk+gAhRUgSZdMeem5ZRcJUbC\nD+wxAoKwcoH6b513dMMQYCZwglitZcnFx+HRwrNpjbzGv/0Xa+jtthpiupAf\n107OFXrf/gy7SFeBT9X5Nb3gCv6gqAsan3DYp8f3DTGIU0dX9R31Qj6HTJ7k\nQx1PVhvPi7/WircQfLIRqfuJOwG7oQkZpP41yXAKhXBAu+IIyAB2xOSvJCZh\nYQsW\r\n=MbL4\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCVE2w9YZb0R42QBQxz1Cw5PEP8A5GJZ5hi+v0LZEhojQIgeAqBmRyJk7j/YmbETgYICoOOrbsc22EmmZjac+KzWmQ="}],"size":2725,"noattachment":false,"key":"/@putout/plugin-convert-for-each-to-for-of/-/@putout/plugin-convert-for-each-to-for-of-3.0.0.tgz"},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/plugin-convert-for-each-to-for-of_3.0.0_1573051001470_0.7897780399410506"},"_hasShrinkwrap":false,"readme":"# @putout/plugin-convert-for-each-to-for-of [![NPM version][NPMIMGURL]][NPMURL]\n\n[NPMIMGURL]: https://img.shields.io/npm/v/@putout/plugin-convert-for-each-to-for-of.svg?style=flat&longCache=true\n[NPMURL]: https://npmjs.org/package/@putout/plugin-convert-for-each-to-for-of \"npm\"\n\n> The [`forEach()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/forEach) method executes a provided function once for each array element.\n>\n> The [`for...of`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for...of) statement creates a loop which invokes a custom iteration hook with statements to be executed for the value of each element of an array.\n>\n> (c) MDN\n\n🐊[**Putout**](https://github.com/coderaiser/putout) plugin adds ability to convert `forEach()` to `for...of`.\nComplements [`@putout/plugin-convert-const-to-let`](https://github.com/coderaiser/putout/tree/master/packages/plugin-convert-const-to-let#readme). Merged to [`@putout/plugin-for-of`](https://www.npmjs.com/package/@putout/plugin-for-of).\n\n## Install\n\n```\nnpm i @putout/plugin-convert-for-each-to-for-of -D\n```\n\n## Rule\n\n```json\n{\n    \"rules\": {\n        \"convert-for-each-to-for-of\": \"on\"\n    }\n}\n```\n\n## ❌ Example of incorrect code\n\n```js\nObject.keys(json).forEach((name) => {\n    manage(name, json[name]);\n});\n\n[].forEach.call(arguments, (item) => {\n    console.log(item);\n});\n```\n\n## ✅ Example of correct code\n\n```js\nfor (const name of Object.keys(json)) {\n    manage(name, json[name]);\n}\n\nfor (const name of arguments) {\n    console.log(item);\n}\n```\n\n## License\n\nMIT\n","publish_time":1573051001597,"_cnpm_publish_time":1573051001597,"dist-tags":{"latest":"8.1.1"}}