{"author":{"name":"Nicholas Jamieson","email":"nicholas@cartant.com"},"bugs":{"url":"https://github.com/cartant/eslint-plugin-etc/issues"},"dependencies":{"@phenomnomnominal/tsquery":"^4.0.0","eslint-etc":"^0.0.14","requireindex":"~1.2.0","tslib":"^2.0.0","tsutils":"^3.0.0","tsutils-etc":"^1.0.0"},"description":"More rules for ESLint","devDependencies":{"@cartant/tslint-config":"^2.0.0","@cartant/tslint-config-etc":"^2.0.0","@types/common-tags":"^1.8.0","@types/eslint":"^6.1.0","@types/mocha":"^7.0.0","@types/node":"^14.0.0","@typescript-eslint/parser":"^3.0.0","common-tags":"^1.8.0","eslint":"^7.0.0","husky":"^4.0.0","lint-staged":"^10.1.1","mocha":"^7.0.0","prettier":"~2.0.0","rimraf":"^3.0.0","ts-node":"^8.0.2","tslint":"^6.0.0","tslint-etc":"^1.6.0","typescript":"~3.9.3"},"homepage":"https://github.com/cartant/eslint-plugin-etc","husky":{"hooks":{"pre-commit":"lint-staged"}},"keywords":["lint","rules","eslint"],"license":"MIT","lint-staged":{"*.{js,ts}":"prettier --write"},"main":"./dist/index.js","name":"eslint-plugin-etc","optionalDependencies":{},"peerDependencies":{"eslint":"^5.0.0 || ^6.0.0 || ^ 7.0.0","typescript":"^3.0.0"},"private":false,"publishConfig":{"tag":"latest"},"repository":{"type":"git","url":"git+https://github.com/cartant/eslint-plugin-etc.git"},"scripts":{"dist":"yarn run lint && yarn run dist:build","dist:build":"yarn run dist:clean && tsc -p tsconfig-dist.json","dist:clean":"rimraf dist","lint":"yarn run lint:source && yarn run lint:tests","lint:source":"tslint --project tsconfig.json source/**/*.ts","lint:tests":"tslint --project tsconfig.json tests/**/*.ts","prepublishOnly":"yarn run test && yarn run dist","prettier":"prettier --write \"./{src,tests}/**/*.{js,json,ts,tsx}\"","prettier:ci":"prettier --check \"./{src,tests}/**/*.{js,json,ts,tsx}\"","test":"mocha -r ts-node/register -t 5000 tests/**/*.ts","test:debug":"mocha -r ts-node/register -t 5000 tests/rules/no-t.ts"},"version":"0.0.1-beta.27","gitHead":"f4cd068aa8a7bf34cdf3907081bd9e82a26743e8","_id":"eslint-plugin-etc@0.0.1-beta.27","_nodeVersion":"13.8.0","_npmVersion":"6.13.6","dist":{"integrity":"sha512-CFdsVkNabTyIYO2qvw2EwZ8w6yqWpQNygZAjcQ84iIBWk8/wNHjNfm6dld/yyQEivSvh58MIP7GmGLS3SYd7lg==","shasum":"bae98bf6f6b4a58a5fba473f694bc02df9608248","tarball":"http://registry-npm.ywwl.com/eslint-plugin-etc/download/eslint-plugin-etc-0.0.1-beta.27.tgz","fileCount":18,"unpackedSize":37122,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeyIeSCRA9TVsSAnZWagAA0SoQAJlw2WbQ6BE0FwqXaixG\nnzRBpGb9ttHI1FhgNI0rktUPtTJ+KpQ5wPKvxn7qZEuRnSEs5QV2RdaKT/KJ\n7TnzYvheK7LlWh/y/J6YZyBtYI/xWx2H/40JD0Xldx0of46PfMaNuAR2HX/Z\nNCf4Bw8WW0IFUrNGHBIwP8ow6KUO6Y/XSBF9snY2C2DHTikOqx67BKXyBSXG\nr/5hTlPDSOI/5ClvhB0pCMjykT678WSbsI6tU7914qAyIHHThosS4USCDLX0\nYZhTdbsivjQCN9n8FofkWnRaS8qs3+rzdVjYVR1//r0gmyPKiriEvcaELIVL\ns+ZYv1VkkDZja4FoXcA3ssc3Ikxt7r3FB3Ta52VqjukBJJWSK29P9kMIyXYA\nxwZIYjY6sGyEYiWLH7bLhA7rwI0CeXNOXt068Br9/oZAEy7gORLI6M4bN9le\nLwEetvzyHKwnTnnZDyTgpAJu2MqDg1OOHB6NRmtAT9e9qn7d/4LcSPar0HJZ\ncCyZ9ghcIWCRr5IxTckoHT9MrZo3uLqS9IXwcciADZITCLDJGKTfuOoJbt15\nlPC1s+2GYOmtzA07yFB5TFEEJkpJ50864I1UlresKGbmHJFT4/aQB1pR2Con\nTsL7pE5sPb1SsJk4oo5FEHuqT5icEcmIdlAL1PFHeQAgIKWZAt4Hd+qJ7EDE\n3CAO\r\n=5A5I\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDnxB+I28PxGF7rpBtp3TMWH/wwmnfxTza+qEHjI+YjBwIgCCTXsbMDtlobwTl5E0uc91RrY8Ho+g5zt84gKUnGu+k="}],"size":8269,"noattachment":false,"key":"/eslint-plugin-etc/-/eslint-plugin-etc-0.0.1-beta.27.tgz"},"maintainers":[{"name":"cartant","email":"nicholas@cartant.com"}],"_npmUser":{"name":"cartant","email":"nicholas@cartant.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/eslint-plugin-etc_0.0.1-beta.27_1590200209836_0.935800243592801"},"_hasShrinkwrap":false,"readme":"# eslint-plugin-etc\n\n[![GitHub License](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/cartant/eslint-plugin-etc/blob/master/LICENSE)\n[![NPM version](https://img.shields.io/npm/v/eslint-plugin-etc.svg)](https://www.npmjs.com/package/eslint-plugin-etc)\n[![Downloads](http://img.shields.io/npm/dm/eslint-plugin-etc.svg)](https://npmjs.org/package/eslint-plugin-etc)\n[![Build status](https://img.shields.io/circleci/build/github/cartant/eslint-plugin-etc?token=8ebc6af0847545d4c2346f5ffaedee508b55ce38)](https://app.circleci.com/pipelines/github/cartant)\n[![dependency status](https://img.shields.io/david/cartant/eslint-plugin-etc.svg)](https://david-dm.org/cartant/eslint-plugin-etc)\n[![devDependency Status](https://img.shields.io/david/dev/cartant/eslint-plugin-etc.svg)](https://david-dm.org/cartant/eslint-plugin-etc#info=devDependencies)\n[![peerDependency Status](https://img.shields.io/david/peer/cartant/eslint-plugin-etc.svg)](https://david-dm.org/cartant/eslint-plugin-etc#info=peerDependencies)\n\nThis package contains a bunch of general-purpose, TypeScript-related ESLint rules. Essentially, it's a re-implementation of the rules that are in the [`tslint-etc`](https://github.com/cartant/tslint-etc) package.\n\nSome of the rules are rather opinionated and are not included in the `recommended` configuration. Developers can decide for themselves whether they want to enable opinionated rules.\n\n# Install\n\nInstall the ESLint TypeScript parser using npm:\n\n```\nnpm install @typescript-eslint/parser --save-dev\n```\n\nInstall the package using npm:\n\n```\nnpm install eslint-plugin-etc --save-dev\n```\n\nConfigure the `parser` and the `parserOptions` for ESLint. Here, I use a `.eslintrc.js` file for the configuration:\n\n```js\nconst { join } = require(\"path\");\nmodule.exports = {\n  parser: \"@typescript-eslint/parser\",\n  parserOptions: {\n    ecmaVersion: 2019,\n    project: join(__dirname, \"./tsconfig.json\"),\n    sourceType: \"module\"\n  },\n  plugins: [\"etc\"],\n  extends: [],\n  rules: {\n    \"etc/no-t\": \"error\"\n  }\n};\n```\n\nOr, using the `recommended` configuration:\n\n```js\nconst { join } = require(\"path\");\nmodule.exports = {\n  parser: \"@typescript-eslint/parser\",\n  parserOptions: {\n    ecmaVersion: 2019,\n    project: join(__dirname, \"./tsconfig.json\"),\n    sourceType: \"module\"\n  },\n  extends: [\"plugin:etc/recommended\"],\n};\n```\n\n# Rules\n\nThe package includes the following rules.\n\nRules marked with ✅ are recommended and rules marked with 🔧 have fixers.\n\n| Rule | Description | | |\n| --- | --- | --- | --- |\n| [`no-assign-mutated-array`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/no-assign-mutated-array.md) | Forbids the assignment of returned, mutated arrays. | ✅ | |\n| [`no-commented-out-code`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/no-commented-out-code.md) | Forbids commented-out code. | | |\n| [`no-const-enum`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/no-const-enum.md) | Forbids the use of `const enum`. Constant enums are [not compatible with isolated modules](https://ncjamieson.com/dont-export-const-enums/). | | |\n| [`no-deprecated`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/no-deprecated.md) | Forbids the use of deprecated APIs. | ✅ | |\n| [`no-enum`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/no-enum.md) | Forbids the use of `enum`. | | |\n| [`no-implicit-any-catch`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/no-implicit-any-catch.md) | Like the [`no-implicit-any-catch` rule](https://github.com/typescript-eslint/typescript-eslint/blob/e01204931e460f5e6731abc443c88d666ca0b07a/packages/eslint-plugin/docs/rules/no-implicit-any-catch.md) in `@typescript-eslint/eslint-plugin`, but for `Promise` rejections instead of `catch` clauses. | ✅ | 🔧 |\n| [`no-internal`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/no-internal.md) | Forbids the use of internal APIs. | ✅ | |\n| [`no-misused-generics`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/no-misused-generics.md) | Forbids type parameters without inference sites and type parameters that don't add type safety to declarations. This is an ESLint port of [Wotan's `no-misused-generics` rule](https://github.com/fimbullinter/wotan/blob/11368a193ba90a9e79b9f6ab530be1b434b122de/packages/mimir/docs/no-misused-generics.md). See also [\"The Golden Rule of Generics\"](https://effectivetypescript.com/2020/08/12/generics-golden-rule/). | | |\n| [`no-t`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/no-t.md) | Forbids single-character type parameters. | | |\n| [`prefer-interface`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/prefer-interface.md) | Forbids type aliases where interfaces can be used. | | 🔧 |\n| [`prefer-less-than`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/prefer-less-than.md) | Forbids greater-than comparisons. (Yes, this is the rule for [Ben Lesh comparisons](https://twitter.com/BenLesh/status/1397593619096166400).) | | 🔧 |\n| [`throw-error`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/throw-error.md) | Forbids throwing - or rejecting with - non-`Error` values. | | |\n| [`underscore-internal`](https://github.com/cartant/eslint-plugin-etc/blob/main/docs/rules/underscore-internal.md) | Forbids internal APIs that are not prefixed with underscores. | | |\n","publish_time":1590200210023,"_cnpm_publish_time":1590200210023,"dist-tags":{"latest":"2.0.3"}}