{"name":"@putout/plugin-remove-unreachable-code","version":"3.0.0","type":"module","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"🐊Putout plugin adds ability to find and remove unreachable code","homepage":"https://github.com/coderaiser/putout/tree/master/packages/plugin-remove-unreachable-code#readme","main":"lib/remove-unreachable-code.js","release":false,"tag":false,"changelog":false,"repository":{"type":"git","url":"git+https://github.com/coderaiser/putout.git"},"scripts":{"test":"madrun test","watch:test":"madrun watch:test","lint":"madrun lint","fresh:lint":"madrun fresh:lint","lint:fresh":"madrun lint:fresh","fix:lint":"madrun fix:lint","coverage":"madrun coverage","report":"madrun report"},"dependencies":{},"keywords":["putout","putout-plugin","plugin","remove","unreachable","code"],"devDependencies":{"@putout/eslint-flat":"^3.0.0","@putout/test":"^13.0.0","c8":"^10.0.0","eslint":"^9.0.0","eslint-plugin-n":"^17.0.0","eslint-plugin-putout":"^27.0.0","madrun":"^11.0.0","nodemon":"^3.0.1"},"peerDependencies":{"putout":">=40"},"license":"MIT","engines":{"node":">=20"},"publishConfig":{"access":"public"},"_id":"@putout/plugin-remove-unreachable-code@3.0.0","gitHead":"33ea779d8a08aabb9ac4f8a09efcf7fc3148cd7a","bugs":{"url":"https://github.com/coderaiser/putout/issues"},"_nodeVersion":"22.15.0","_npmVersion":"11.1.0","dist":{"integrity":"sha512-AL4J+oNULhniVs0DuTDpFAzFLtdrQR62mazGaAPhc1hNOch2Gn+o7j/TZ1FEgQ1mMoi6U3xKCSXbh+Z6ABbr7A==","shasum":"048780d8ed1d157c7241851e809e3af4e8a0abab","tarball":"http://registry-npm.ywwl.com/@putout/plugin-remove-unreachable-code/download/@putout/plugin-remove-unreachable-code-3.0.0.tgz","fileCount":4,"unpackedSize":5029,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQC2rtCZ+2OFYdK+by9JfdYUAaNt6fViC82cN0IJaQMVjgIhANpDd40negTnwZhjPYSjb9VUfsvWfpdEX39o06hHhvLf"}],"size":2260,"noattachment":false,"key":"/@putout/plugin-remove-unreachable-code/-/@putout/plugin-remove-unreachable-code-3.0.0.tgz"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/plugin-remove-unreachable-code_3.0.0_1748443962097_0.42931194699854003"},"_hasShrinkwrap":false,"readme":"# @putout/plugin-remove-unreachable-code [![NPM version][NPMIMGURL]][NPMURL]\n\n[NPMIMGURL]: https://img.shields.io/npm/v/@putout/plugin-remove-unreachable-code.svg?style=flat&longCache=true\n[NPMURL]: https://npmjs.org/package/@putout/plugin-remove-unreachable-code\"npm\"\n\n> The **JavaScript** warning \"unreachable code after return statement\" occurs when using an expression after a return statement, or when using a semicolon-less return statement but including an expression directly after.\n>\n> (c) [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Errors/Stmt_after_return)\n\n🐊[**Putout**](https://github.com/coderaiser/putout) plugin adds ability to find and remove unreachable code.\n\n## Install\n\n```\nnpm i @putout/plugin-remove-unreachable-code\n```\n\n## Rule\n\n```json\n{\n    \"rules\": {\n        \"remove-unreachable-code\": \"on\"\n    }\n}\n```\n\n## ❌ Example of incorrect code\n\n```js\nfunction hi() {\n    return 'world';\n    console.log('hello');\n}\n\nfunction log() {\n    throw Error('error');\n    \n    console.log('hello');\n}\n```\n\n## ✅ Example of correct code\n\n```js\nfunction hi() {\n    return 'world';\n}\n\nfunction log() {\n    throw Error('error');\n}\n```\n\n## License\n\nMIT\n","publish_time":1748443962262,"_cnpm_publish_time":1748443962262,"dist-tags":{"latest":"3.0.0"}}