{"name":"@putout/plugin-convert-object-entries-to-object-keys","version":"1.0.1","keywords":["putout","putout-plugin","plugin","convert","const","let","var","VariableDeclaration"],"author":{"url":"https://github.com/coderaiser","name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"license":"MIT","_id":"@putout/plugin-convert-object-entries-to-object-keys@1.0.1","maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"homepage":"https://github.com/coderaiser/putout/tree/master/packages/plugin-convert-object-entries-to-object-keys#readme","bugs":{"url":"https://github.com/coderaiser/putout/issues"},"tag":false,"dist":{"shasum":"59ae222d2607a1269b7c8c757ade1269d6937806","tarball":"http://registry-npm.ywwl.com/@putout/plugin-convert-object-entries-to-object-keys/download/@putout/plugin-convert-object-entries-to-object-keys-1.0.1.tgz","fileCount":4,"integrity":"sha512-jD0Bpqn2/uEinTT2T5o5a6fVGOSCXUh+VzT5CwC1BjzHg8NsJxMV22MZeLm0J5iBV584ARqi9tYYnujSIX6mwQ==","signatures":[{"sig":"MEUCIQDfnY8Hv/dlnuw6MDoxscjpRYkBOTHaZVg2jOTa5UCAOgIgVSo9S+1ufOonMzhJDX3+GuBwD+DVlt6kVPPGr4wy8Gw=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":4499,"size":2104,"noattachment":false,"key":"/@putout/plugin-convert-object-entries-to-object-keys/-/@putout/plugin-convert-object-entries-to-object-keys-1.0.1.tgz"},"main":"lib/convert-object-entries-to-object-keys.js","type":"module","engines":{"node":">=20"},"gitHead":"6016804a7373dd5db493c423aa17106af64ab4bd","release":false,"scripts":{"lint":"madrun lint","test":"madrun test","report":"madrun report","coverage":"madrun coverage","fix:lint":"madrun fix:lint","fresh:lint":"madrun fresh:lint","lint:fresh":"madrun lint:fresh","watch:test":"madrun watch:test"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"changelog":false,"repository":{"url":"git+https://github.com/coderaiser/putout.git","type":"git"},"_npmVersion":"11.4.2","description":"🐊Putout plugin adds ability to convert 'Object.entries()' to 'Object.keys()'","directories":{},"_nodeVersion":"24.6.0","dependencies":{},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"^10.0.0","eslint":"^9.0.0","madrun":"^11.0.0","@putout/test":"^14.0.0","eslint-plugin-n":"^17.0.0","eslint-plugin-putout":"^28.0.0"},"peerDependencies":{"putout":">=40"},"_npmOperationalInternal":{"tmp":"tmp/plugin-convert-object-entries-to-object-keys_1.0.1_1756398835221_0.9788271784073097","host":"s3://npm-registry-packages-npm-production"},"readme":"# @putout/plugin-convert-object-entries-to-object-keys [![NPM version][NPMIMGURL]][NPMURL]\n\n[NPMIMGURL]: https://img.shields.io/npm/v/@putout/plugin-convert-object-entries-to-object-keys.svg?style=flat&longCache=true\n[NPMURL]: https://npmjs.org/package/@putout/plugin-convert-object-entreis-to-object-keys \"npm\"\n\n> The `Object.keys()` static method returns an array of a given object's own enumerable string-keyed property key-value pairs.\n>\n> (c) [`Object.keys()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/keys)\n\n> The `Object.entries()` static method returns an array of a given object's own enumerable string-keyed property key-value pairs.\n>\n> (c) [`Object.entries()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/entries)\n\n🐊[**Putout**](https://github.com/coderaiser/putout) plugin adds ability to convert `Object.entries()` to `Object.keys()`\n\n## Install\n\n```\nnpm i @putout/plugin-convert-object-entries-to-object-keys -D\n```\n\nCheckout in 🐊[**Putout Editor**](https://putout.cloudcmd.io/#/gist/82cf60991515c274d0ba08f2ca36e9e6/a56a4bddfb45007434f2d24e9573a3d7646ea11d).\n\n## Rule\n\n```json\n{\n    \"rules\": {\n        \"convert-object-entries-to-object-keys\": \"on\"\n    }\n}\n```\n\n## ❌ Example of incorrect code\n\n```js\nfor (const [name] of Object.entries(tokens)) {\n    console.log(name);\n}\n\nfor (const [name] of entries(tokens)) {\n    console.log(name);\n}\n```\n\n## ✅ Example of correct code\n\n```js\nfor (const name of Object.keys(tokens)) {\n    console.log(name);\n}\n\nfor (const name of keys(tokens)) {\n    console.log(name);\n}\n```\n\n## License\n\nMIT\n","publish_time":1756398835410,"_cnpm_publish_time":1756398835410,"dist-tags":{"latest":"1.0.2"}}