Skip to content

Commit 96e48ca

Browse files
committed
[Fix] add missing optional peer dependencies
1 parent 6682e9a commit 96e48ca

File tree

4 files changed

+15
-1
lines changed

4 files changed

+15
-1
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ rules:
163163

164164
You may use the following shortcut or assemble your own config using the granular settings described below.
165165

166-
Make sure you have installed [`@typescript-eslint/parser`] which is used in the following configuration. Unfortunately NPM does not allow to list optional peer dependencies.
166+
Make sure you have installed [`@typescript-eslint/parser`] which is used in the following configuration.
167167

168168
```yaml
169169
extends:

package.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,11 @@
9494
"typescript": "^2.8.1 || ~3.9.5",
9595
"typescript-eslint-parser": "^15 || ^22.0.0"
9696
},
97+
"peerDependenciesMeta": {
98+
"@typescript-eslint/parser": {
99+
"optional": true
100+
}
101+
},
97102
"peerDependencies": {
98103
"eslint": "^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8"
99104
},

utils/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).
44
This change log adheres to standards from [Keep a CHANGELOG](http://keepachangelog.com).
55

66
## Unreleased
7+
- add missing optional peer dependencies ([#2283], thanks [@jdanil])
78

89
## v2.7.1 - 2021-10-13
910

utils/package.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,14 @@
2525
"url": "https://github.com/import-js/eslint-plugin-import/issues"
2626
},
2727
"homepage": "https://github.com/import-js/eslint-plugin-import#readme",
28+
"peerDependenciesMeta": {
29+
"@typescript-eslint/parser": {
30+
"optional": true
31+
},
32+
"eslint-import-resolver-node": {
33+
"optional": true
34+
}
35+
},
2836
"dependencies": {
2937
"debug": "^3.2.7",
3038
"find-up": "^2.1.0",

0 commit comments

Comments
 (0)