@vue/eslint-config-typescript
Advanced tools
Comparing version 9.1.0 to 10.0.0
{ | ||
"name": "@vue/eslint-config-typescript", | ||
"version": "9.1.0", | ||
"version": "10.0.0", | ||
"description": "eslint-config-typescript for vue-cli", | ||
@@ -10,5 +10,2 @@ "main": "index.js", | ||
], | ||
"scripts": { | ||
"test": "jest" | ||
}, | ||
"publishConfig": { | ||
@@ -23,3 +20,5 @@ "access": "public" | ||
"vue", | ||
"cli" | ||
"cli", | ||
"eslint", | ||
"typescript" | ||
], | ||
@@ -33,4 +32,2 @@ "author": "Evan You", | ||
"devDependencies": { | ||
"@typescript-eslint/eslint-plugin": "^5.0.0", | ||
"@typescript-eslint/parser": "^5.0.0", | ||
"eslint": "^8.0.0", | ||
@@ -46,4 +43,2 @@ "eslint-plugin-vue": "^8.0.1", | ||
"peerDependencies": { | ||
"@typescript-eslint/eslint-plugin": "^5.0.0", | ||
"@typescript-eslint/parser": "^5.0.0", | ||
"eslint": "^6.2.0 || ^7.0.0 || ^8.0.0", | ||
@@ -53,2 +48,4 @@ "eslint-plugin-vue": "^8.0.1" | ||
"dependencies": { | ||
"@typescript-eslint/eslint-plugin": "^5.0.0", | ||
"@typescript-eslint/parser": "^5.0.0", | ||
"vue-eslint-parser": "^8.0.0" | ||
@@ -58,3 +55,7 @@ }, | ||
"node": "^12.22.0 || ^14.17.0 || >=16.0.0" | ||
} | ||
} | ||
}, | ||
"scripts": { | ||
"test": "jest" | ||
}, | ||
"readme": "# @vue/eslint-config-typescript\n\n> eslint-config-typescript for Vue\n\nSee [@typescript-eslint/eslint-plugin](https://typescript-eslint.io/rules/) for available rules.\n\nThis config is specifically designed to be used by `@vue/cli` & `create-vue` setups\nand is not meant for outside use (it can be used but some adaptations\non the user side might be needed - for details see the config file).\n\nA part of its design is that this config may implicitly depend on\nother parts of `@vue/cli`/`create-vue` setups, such as `eslint-plugin-vue` being\nextended in the same resulting config.\n\n## Installation\n\nIn order to work around [a known limitation in ESLint](https://github.com/eslint/eslint/issues/3458), we recommend you to use this package alongside `@rushstack/eslint-patch`, so that you don't have to install too many dependencies:\n\n```sh\nnpm add --dev @vue/eslint-config-typescript @rushstack/eslint-patch\n```\n\n## Usage\n\nThis package comes with 2 rulesets.\n\n### `@vue/eslint-config-typescript`\n\nThis ruleset is the base configuration for Vue-TypeScript projects.\nBesides setting the parser and plugin options, it also turns off several conflicting rules in the `eslint:recommended` ruleset.\nSo when used alongside other sharable configs, this config should be placed at the end of the `extends` array.\n\nAn example `.eslintrc.cjs`:\n\n```js\n/* eslint-env node */\nrequire(\"@rushstack/eslint-patch/modern-module-resolution\")\n\nmodule.exports = {\n extends: [\n 'eslint:recommended',\n 'plugin:vue/vue3-essential',\n '@vue/eslint-config-typescript'\n ]\n}\n```\n\n### `@vue/eslint-config-typescript/recommended`\n\nThis is extended from the `@typescript-eslint/recommended` ruleset, which is an **_opinionated_** ruleset.\nSee the [original documentation](https://github.com/typescript-eslint/typescript-eslint/tree/master/packages/eslint-plugin/src/configs#recommended) for more information.\n\nSome of its rules, however, might conflict with `prettier`.\nSo when used alongside other sharable configs, this config should be placed after all other configs except for the one from `@vue/eslint-config-prettier` or `eslint-plugin-prettier` in the `extends` array.\n\nAn example `.eslintrc.cjs`:\n\n```js\n/* eslint-env node */\nrequire(\"@rushstack/eslint-patch/modern-module-resolution\")\n\nmodule.exports = {\n extends: [\n 'plugin:vue/vue3-essential',\n '@vue/eslint-config-typescript/recommended',\n '@vue/eslint-config-prettier'\n ]\n}\n```\n\n### With Other Community Configs\n\nWork-In-Progress.\n\n~~If you are following the [`standard`](https://standardjs.com/) or [`airbnb`](https://github.com/airbnb/javascript/) style guides, don't manually extend from this package. Please use `@vue/eslint-config-standard-with-typescript` or `@vue/eslint-config-airbnb-with-typescript` instead.~~\n" | ||
} |
# @vue/eslint-config-typescript | ||
> eslint-config-typescript for vue-cli | ||
> eslint-config-typescript for Vue | ||
See [@typescript-eslint/eslint-plugin](https://typescript-eslint.io/eslint-plugin) for available rules. | ||
See [@typescript-eslint/eslint-plugin](https://typescript-eslint.io/rules/) for available rules. | ||
This config is specifically designed to be used by Vue CLI setups | ||
This config is specifically designed to be used by `@vue/cli` & `create-vue` setups | ||
and is not meant for outside use (it can be used but some adaptations | ||
@@ -12,3 +12,3 @@ on the user side might be needed - for details see the config file). | ||
A part of its design is that this config may implicitly depend on | ||
other parts of Vue CLI setups, such as `eslint-plugin-vue` being | ||
other parts of `@vue/cli`/`create-vue` setups, such as `eslint-plugin-vue` being | ||
extended in the same resulting config. | ||
@@ -18,6 +18,6 @@ | ||
This config requires several peer dependencies. So it's recommended to use the `install-peerdeps` command: | ||
In order to work around [a known limitation in ESLint](https://github.com/eslint/eslint/issues/3458), we recommend you to use this package alongside `@rushstack/eslint-patch`, so that you don't have to install too many dependencies: | ||
```sh | ||
npx install-peerdeps --dev @vue/eslint-config-typescript | ||
npm add --dev @vue/eslint-config-typescript @rushstack/eslint-patch | ||
``` | ||
@@ -35,10 +35,13 @@ | ||
An example `.eslintrc.js`: | ||
An example `.eslintrc.cjs`: | ||
```js | ||
/* eslint-env node */ | ||
require("@rushstack/eslint-patch/modern-module-resolution") | ||
module.exports = { | ||
extends: [ | ||
'plugin:vue/essential', | ||
'eslint:recommended', | ||
'@vue/typescript' | ||
'plugin:vue/vue3-essential', | ||
'@vue/eslint-config-typescript' | ||
] | ||
@@ -54,16 +57,23 @@ } | ||
Some of its rules, however, might conflict with `prettier`. | ||
So when used alongside other sharable configs, this config should be placed after all other configs except for the one from `eslint-plugin-prettier` in the `extends` array. | ||
So when used alongside other sharable configs, this config should be placed after all other configs except for the one from `@vue/eslint-config-prettier` or `eslint-plugin-prettier` in the `extends` array. | ||
An example `.eslintrc.js`: | ||
An example `.eslintrc.cjs`: | ||
```js | ||
/* eslint-env node */ | ||
require("@rushstack/eslint-patch/modern-module-resolution") | ||
module.exports = { | ||
extends: [ | ||
'plugin:vue/essential', | ||
'@vue/airbnb', | ||
'@vue/typescript/recommended', | ||
'plugin:prettier/recommended' | ||
'plugin:vue/vue3-essential', | ||
'@vue/eslint-config-typescript/recommended', | ||
'@vue/eslint-config-prettier' | ||
] | ||
} | ||
``` | ||
### With Other Community Configs | ||
Work-In-Progress. | ||
~~If you are following the [`standard`](https://standardjs.com/) or [`airbnb`](https://github.com/airbnb/javascript/) style guides, don't manually extend from this package. Please use `@vue/eslint-config-standard-with-typescript` or `@vue/eslint-config-airbnb-with-typescript` instead.~~ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
9681
8
76