@wordpress/eslint-plugin 13.2.0 → 13.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -4
- package/CHANGELOG.md +0 -354
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wordpress/eslint-plugin",
|
|
3
|
-
"version": "13.
|
|
3
|
+
"version": "13.3.0",
|
|
4
4
|
"description": "ESLint plugin for WordPress development.",
|
|
5
5
|
"author": "The WordPress Contributors",
|
|
6
6
|
"license": "GPL-2.0-or-later",
|
|
@@ -34,8 +34,8 @@
|
|
|
34
34
|
"@babel/eslint-parser": "^7.16.0",
|
|
35
35
|
"@typescript-eslint/eslint-plugin": "^5.3.0",
|
|
36
36
|
"@typescript-eslint/parser": "^5.3.0",
|
|
37
|
-
"@wordpress/babel-preset-default": "^7.
|
|
38
|
-
"@wordpress/prettier-config": "^2.
|
|
37
|
+
"@wordpress/babel-preset-default": "^7.3.0",
|
|
38
|
+
"@wordpress/prettier-config": "^2.2.0",
|
|
39
39
|
"cosmiconfig": "^7.0.0",
|
|
40
40
|
"eslint-config-prettier": "^8.3.0",
|
|
41
41
|
"eslint-plugin-import": "^2.25.2",
|
|
@@ -65,5 +65,5 @@
|
|
|
65
65
|
"publishConfig": {
|
|
66
66
|
"access": "public"
|
|
67
67
|
},
|
|
68
|
-
"gitHead": "
|
|
68
|
+
"gitHead": "8d42d2febb7d0ba8372a33e560a62f5a5f6a9112"
|
|
69
69
|
}
|
package/CHANGELOG.md
DELETED
|
@@ -1,354 +0,0 @@
|
|
|
1
|
-
<!-- Learn how to maintain this file at https://github.com/WordPress/gutenberg/tree/HEAD/packages#maintaining-changelogs. -->
|
|
2
|
-
|
|
3
|
-
## Unreleased
|
|
4
|
-
|
|
5
|
-
## 13.2.0 (2022-09-21)
|
|
6
|
-
|
|
7
|
-
## 13.0.0 (2022-08-24)
|
|
8
|
-
|
|
9
|
-
### Breaking Change
|
|
10
|
-
|
|
11
|
-
- Increase the minimum Node.js version to 14 and minimum npm version to 6.14.4 ([#43141](https://github.com/WordPress/gutenberg/pull/43141)).
|
|
12
|
-
- Remove all rules targeting test files from the `recommended` and `recommended-with-formatting` presets when Jest package is installed ([#43272](https://github.com/WordPress/gutenberg/pull/43272)).
|
|
13
|
-
|
|
14
|
-
## 12.8.0 (2022-07-27)
|
|
15
|
-
|
|
16
|
-
### Code Quality
|
|
17
|
-
|
|
18
|
-
- Remove deprecated rules `no-negated-in-lhs` replaced with `no-unsafe-negation`, and `jsx-a11y/label-has-for` replaced with `jsx-a11/label-has-associated-control` ([#42654](https://github.com/WordPress/gutenberg/pull/42654)).
|
|
19
|
-
|
|
20
|
-
## 12.6.0 (2022-06-29)
|
|
21
|
-
|
|
22
|
-
- Enable `no-unused-vars`'s setting `ignoreRestSiblings` to allow unused variables when destructuring with rest properties ([#41897](https://github.com/WordPress/gutenberg/pull/41897)).
|
|
23
|
-
|
|
24
|
-
## 12.2.0 (2022-05-04)
|
|
25
|
-
|
|
26
|
-
### Bug Fix
|
|
27
|
-
|
|
28
|
-
- Fix the `recommended` preset when Prettier is not installed ([#40634](https://github.com/WordPress/gutenberg/pull/40634)).
|
|
29
|
-
|
|
30
|
-
## 12.0.0 (2022-04-08)
|
|
31
|
-
|
|
32
|
-
### Breaking Changes
|
|
33
|
-
|
|
34
|
-
- Revert the removal of the automatic environment detection of `test-unit` and `test-e2e` for the `recommended` preset. However, They will still be disabled if `@playwright/test` is installed in the project.
|
|
35
|
-
|
|
36
|
-
## 11.0.0 (2022-03-11)
|
|
37
|
-
|
|
38
|
-
### Breaking Changes
|
|
39
|
-
|
|
40
|
-
- The integration with [Prettier](https://prettier.io) is now optional and gets activated when the `prettier` package is installed in the project ([#39244](https://github.com/WordPress/gutenberg/pull/39244)).
|
|
41
|
-
|
|
42
|
-
### Bug Fix
|
|
43
|
-
|
|
44
|
-
- Replaced no-shadow eslint rule with @typescript-eslint/no-shadow ([#38665](https://github.com/WordPress/gutenberg/pull/38665)).
|
|
45
|
-
|
|
46
|
-
### Breaking Changes
|
|
47
|
-
|
|
48
|
-
- Remove automatic environment detection of `test-unit` and `test-e2e` for the `recommended` preset. It's now recommended to opt-in to specific preset explicitly.
|
|
49
|
-
|
|
50
|
-
## 10.0.0 (2022-01-27)
|
|
51
|
-
|
|
52
|
-
### Breaking Changes
|
|
53
|
-
|
|
54
|
-
- The peer dependency constraint for ESLint has been updated from `^6 || ^7` to `^8`.
|
|
55
|
-
- The bundled `@typescript-eslint/eslint-plugin` dependency has been updated from requiring `^4.31.0` to requiring `^5.3.0` ([#36283](https://github.com/WordPress/gutenberg/pull/36283)).
|
|
56
|
-
- The bundled `@typescript-eslint/parser` dependency has been updated from requiring `^4.31.0` to requiring `^5.3.0` ([#36283](https://github.com/WordPress/gutenberg/pull/36283)).
|
|
57
|
-
- The bundled `eslint-config-prettier` dependency has been updated from requiring `^7.1.0` to requiring `^8.3.0` ([#36283](https://github.com/WordPress/gutenberg/pull/36283)).
|
|
58
|
-
- The bundled `eslint-plugin-jest` dependency has been updated from requiring `^24.1.3` to requiring `^25.2.3` ([#36283](https://github.com/WordPress/gutenberg/pull/36283)).
|
|
59
|
-
- The bundled `eslint-plugin-jsdoc` dependency has been updated from requiring `^36.0.8` to requiring `^37.0.3` ([#36283](https://github.com/WordPress/gutenberg/pull/36283)).
|
|
60
|
-
- The bundled `globals` dependency has been updated from requiring `^12.0.0` to requiring `^13.12.0` ([#36283](https://github.com/WordPress/gutenberg/pull/36283)).
|
|
61
|
-
- The `gutenberg-phase` rule has been deprecated and replaced by the `is-gutenberg-plugin` rule. ([#38202](https://github.com/WordPress/gutenberg/pull/38202))
|
|
62
|
-
|
|
63
|
-
### Enhancement
|
|
64
|
-
|
|
65
|
-
- Omit verification for WordPress dependencies in the import statements since they get externalized when used with WordPress ([#37639](https://github.com/WordPress/gutenberg/pull/37639)).
|
|
66
|
-
|
|
67
|
-
### Bug Fix
|
|
68
|
-
|
|
69
|
-
- Fix Babel config resolution when a custom ESLint config present ([#37406](https://github.com/WordPress/gutenberg/pull/37406)). Warning: it won't recognize the `babel.config.json` file present in the project until the upstream bug in `cosmiconfig` is fixed.
|
|
70
|
-
|
|
71
|
-
## 9.3.0 (2021-11-15)
|
|
72
|
-
|
|
73
|
-
### Enhancements
|
|
74
|
-
|
|
75
|
-
- Replaced deprecated `babel-eslint` dependency with `@babel/eslint-parser` ([#36244](https://github.com/WordPress/gutenberg/pull/36244)).
|
|
76
|
-
- The bundled `eslint-plugin-import` dependency has been updated from requiring `^2.23.4` to requiring `^2.25.2` ([#36244](https://github.com/WordPress/gutenberg/pull/36244)).
|
|
77
|
-
|
|
78
|
-
## 9.2.0 (2021-10-12)
|
|
79
|
-
|
|
80
|
-
### Enhancement
|
|
81
|
-
|
|
82
|
-
- The bundled `eslint-plugin-jsdoc` dependency has been updated from requiring `^34.1.0` to requiring `^36.0.8` ([#34338](https://github.com/WordPress/gutenberg/pull/34338)).
|
|
83
|
-
|
|
84
|
-
### Bug Fix
|
|
85
|
-
|
|
86
|
-
- Use Jest related rules only when the `jest` package is installed ([#33120](https://github.com/WordPress/gutenberg/pull/33120)).
|
|
87
|
-
|
|
88
|
-
## 9.1.2 (2021-09-09)
|
|
89
|
-
|
|
90
|
-
### Bug Fix
|
|
91
|
-
|
|
92
|
-
- The recommended configuration will now respect `type` imports in TypeScript files ([#34055](https://github.com/WordPress/gutenberg/pull/34055)).
|
|
93
|
-
|
|
94
|
-
## 9.1.1 (2021-08-23)
|
|
95
|
-
|
|
96
|
-
### Bug Fix
|
|
97
|
-
|
|
98
|
-
- Include `.jsx` extension when linting import statements in case TypeScript not present ([#33746](https://github.com/WordPress/gutenberg/pull/33746)).
|
|
99
|
-
|
|
100
|
-
## 9.1.0 (2021-07-21)
|
|
101
|
-
|
|
102
|
-
### Enhancement
|
|
103
|
-
|
|
104
|
-
- Adds JSDoc alignment check ([#25300](https://github.com/WordPress/gutenberg/pull/25300)).
|
|
105
|
-
|
|
106
|
-
## 9.0.1 (2021-03-19)
|
|
107
|
-
|
|
108
|
-
### Bug Fix
|
|
109
|
-
|
|
110
|
-
- Adds TypeScript as a peer dependency and makes it optional when not installed ([#29942](https://github.com/WordPress/gutenberg/pull/29942)).
|
|
111
|
-
|
|
112
|
-
## 9.0.0 (2021-03-17)
|
|
113
|
-
|
|
114
|
-
### Breaking Changes
|
|
115
|
-
|
|
116
|
-
- Add support and configuration for TypeScript files. [#27143](https://github.com/WordPress/gutenberg/pull/27143)
|
|
117
|
-
|
|
118
|
-
### New Features
|
|
119
|
-
|
|
120
|
-
- Enabled `import/default` and `import/named` rules in the `recommended` ruleset. [#28513](https://github.com/WordPress/gutenberg/pull/28513)
|
|
121
|
-
- Add new rule `@wordpress/data-no-store-string-literals` to discourage passing string literals to reference data stores ([#28726](https://github.com/WordPress/gutenberg/pull/28726)).
|
|
122
|
-
|
|
123
|
-
## 8.0.1 (2021-01-28)
|
|
124
|
-
|
|
125
|
-
### Bug Fix
|
|
126
|
-
|
|
127
|
-
- Add missing `eslint-plugin-import` npm dependency ([#28545](https://github.com/WordPress/gutenberg/pull/28545)).
|
|
128
|
-
|
|
129
|
-
## 8.0.0 (2021-01-21)
|
|
130
|
-
|
|
131
|
-
### Breaking Changes
|
|
132
|
-
|
|
133
|
-
- Increase the minimum Node.js version to 12 ([#27934](https://github.com/WordPress/gutenberg/pull/27934)).
|
|
134
|
-
- Enabled `import/no-extraneous-dependencies` rule in the `recommended` ruleset.
|
|
135
|
-
- Enabled `import/no-unresolved` rule in the `recommended` ruleset.
|
|
136
|
-
- Enabled `no-unsafe-wp-apis` rule in the `recommended` ruleset ([#27327](https://github.com/WordPress/gutenberg/pull/27327)).
|
|
137
|
-
- The bundled `eslint-config-prettier` dependency has been updated from requiring `^6.10.1` to requiring `^7.1.0` ([#27965](https://github.com/WordPress/gutenberg/pull/27965)).
|
|
138
|
-
- The bundled `eslint-plugin-jest` dependency has been updated from requiring `^23.8.2` to requiring `^24.1.3` ([#27965](https://github.com/WordPress/gutenberg/pull/27965)).
|
|
139
|
-
|
|
140
|
-
### Enhancements
|
|
141
|
-
|
|
142
|
-
- The bundled `eslint-plugin-jsdoc` dependency has been updated from requiring `^30.2.2` to requiring `^30.7.13` ([#27965](https://github.com/WordPress/gutenberg/pull/27965)).
|
|
143
|
-
- The bundled `eslint-plugin-jsx-a11y` dependency has been updated from requiring `^6.2.3` to requiring `^6.4.1` ([#27965](https://github.com/WordPress/gutenberg/pull/27965)).
|
|
144
|
-
- The bundled `eslint-plugin-prettier` dependency has been updated from requiring `^3.1.2` to requiring `^3.3.0` ([#27965](https://github.com/WordPress/gutenberg/pull/27965)).
|
|
145
|
-
- The bundled `eslint-plugin-react` dependency has been updated from requiring `^7.20.0` to requiring `^7.22.0` ([#27965](https://github.com/WordPress/gutenberg/pull/27965)).
|
|
146
|
-
- The bundled `eslint-plugin-react-hooks` dependency has been updated from requiring `^4.0.4` to requiring `^4.2.0` ([#27965](https://github.com/WordPress/gutenberg/pull/27965)).
|
|
147
|
-
|
|
148
|
-
## 7.4.0 (2020-12-17)
|
|
149
|
-
|
|
150
|
-
### New Feature
|
|
151
|
-
|
|
152
|
-
- Add `no-unsafe-wp-apis` rule to discourage usage of unsafe APIs ([#27301](https://github.com/WordPress/gutenberg/pull/27301)).
|
|
153
|
-
|
|
154
|
-
### Enhancements
|
|
155
|
-
|
|
156
|
-
- The bundled `wp-prettier` dependency has been upgraded from `2.0.5` to `2.2.1`.
|
|
157
|
-
|
|
158
|
-
### Documentation
|
|
159
|
-
|
|
160
|
-
- Include a note about the minimum version required for `node` (10.0.0) and `npm` (6.9.0).
|
|
161
|
-
|
|
162
|
-
## 7.2.1 (2020-09-17)
|
|
163
|
-
|
|
164
|
-
### Bug Fixes
|
|
165
|
-
|
|
166
|
-
- Fix TypeError for projects without a local Prettier configuration.
|
|
167
|
-
|
|
168
|
-
## 7.2.0 (2020-09-03)
|
|
169
|
-
|
|
170
|
-
### Enhancements
|
|
171
|
-
|
|
172
|
-
- The bundled `eslint-plugin-jsdoc` dependency has been updated from requiring `^26.0.0` to requiring `^30.2.2`.
|
|
173
|
-
|
|
174
|
-
### Bug Fixes
|
|
175
|
-
|
|
176
|
-
- The recommended configuration will now respect local Prettier configuration. These are merged to the default WordPress configuration.
|
|
177
|
-
|
|
178
|
-
## 7.1.0-rc.0 (2020-06-24)
|
|
179
|
-
|
|
180
|
-
### Enhancements
|
|
181
|
-
|
|
182
|
-
- Support ESLint `^7` as peer dependency.
|
|
183
|
-
|
|
184
|
-
## 7.0.0 (2020-06-15)
|
|
185
|
-
|
|
186
|
-
### Breaking Changes
|
|
187
|
-
|
|
188
|
-
- The bundled `wp-prettier` dependency has been upgraded from `1.19.1` to `2.0.5`. Refer to the [Prettier 2.0 "2020" blog post](https://prettier.io/blog/2020/03/21/2.0.0.html) for full details about the major changes included in Prettier 2.0.
|
|
189
|
-
- The bundled `eslint-plugin-react-hooks` dependency has been updated from requiring `^3.0.0` to requiring `^4.0.4`.
|
|
190
|
-
- The bundled `eslint-plugin-jsdoc` dependency has been updated from requiring `^22.1.0` to requiring `^26.0.0`.
|
|
191
|
-
|
|
192
|
-
### Enhancements
|
|
193
|
-
|
|
194
|
-
- The bundled `eslint-plugin-react` dependency has been updated from requiring `^7.19.0` to requiring `^7.20.0`.
|
|
195
|
-
|
|
196
|
-
## 6.1.0 (2020-05-28)
|
|
197
|
-
|
|
198
|
-
### Bug Fixes
|
|
199
|
-
|
|
200
|
-
- `@wordpress/dependency-group` will now correctly identify issues associated with CommonJS (`require`) module imports.
|
|
201
|
-
|
|
202
|
-
## 6.0.0 (2020-05-14)
|
|
203
|
-
|
|
204
|
-
### Breaking Changes
|
|
205
|
-
|
|
206
|
-
- The severity of the rule, `jsdoc/no-undefined-types`, has been increased from `warn` to `error`. In addition, `JSX` has been added to the default list of defined types.
|
|
207
|
-
|
|
208
|
-
### Improvements
|
|
209
|
-
|
|
210
|
-
- `'AsyncIterableIterator'` is now allowed as a valid TypeScript utility type.
|
|
211
|
-
|
|
212
|
-
## 5.1.0 (2020-04-30)
|
|
213
|
-
|
|
214
|
-
### Bug Fixes
|
|
215
|
-
|
|
216
|
-
- The `@wordpress/no-unused-vars-before-return` rule will now correctly identify valid usage of a variable as a JSX identifier.
|
|
217
|
-
- Make `@wordpress/i18n-text-domain` rule less strict by default. When `allowedTextDomain` option is not provided it allows now skipping text domain or providing any string ([#21928](https://github.com/WordPress/gutenberg/pull/21928)).
|
|
218
|
-
|
|
219
|
-
## 5.0.1 (2020-04-15)
|
|
220
|
-
|
|
221
|
-
### Bug Fixes
|
|
222
|
-
|
|
223
|
-
- Fixes an error caused by missing `utils` directory from published package ([#21609](https://github.com/WordPress/gutenberg/pull/21609)).
|
|
224
|
-
- Added the recommended `Prettier` config that enforces WordPress coding style guidelines ([#21602](https://github.com/WordPress/gutenberg/pull/21602)).
|
|
225
|
-
|
|
226
|
-
## 5.0.0 (2020-04-15)
|
|
227
|
-
|
|
228
|
-
### Breaking Changes
|
|
229
|
-
|
|
230
|
-
- There is a new `i18n` ruleset that includes all i18n-related rules and is included in the `recommended` ruleset.
|
|
231
|
-
- The `@wordpress/valid-sprintf` rule has been moved from the `custom` ruleset to the `i18n` ruleset.
|
|
232
|
-
- The `@wordpress/valid-sprintf` rule now recognizes mix of ordered and non-ordered placeholders.
|
|
233
|
-
- The bundled `eslint-plugin-jest` dependency has been updated from requiring `^22.15.1` to requiring `^23.8.2` ([#21424](https://github.com/WordPress/gutenberg/pull/21424)).
|
|
234
|
-
- The bundled `eslint-plugin-jsdoc` dependency has been updated from requiring `^21.0.0` to requiring `^22.1.0` ([#21424](https://github.com/WordPress/gutenberg/pull/21424)).
|
|
235
|
-
- The bundled `eslint-plugin-react-hooks` dependency has been updated from requiring `^1.6.1` to requiring `^3.0.0` ([#21424](https://github.com/WordPress/gutenberg/pull/21424)).
|
|
236
|
-
|
|
237
|
-
### New Features
|
|
238
|
-
|
|
239
|
-
- New Rule: [`@wordpress/i18n-text-domain`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/i18n-text-domain.md)
|
|
240
|
-
- New Rule: [`@wordpress/i18n-translator-comments`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/i18n-translator-comments.md)
|
|
241
|
-
- New Rule: [`@wordpress/i18n-no-variables`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/i18n-no-variables.md)
|
|
242
|
-
- New Rule: [`@wordpress/i18n-no-placeholders-only`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/i18n-no-placeholders-only.md)
|
|
243
|
-
- New Rule: [`@wordpress/i18n-no-collapsible-whitespace`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/i18n-no-collapsible-whitespace.md)
|
|
244
|
-
- New Rule: [`@wordpress/i18n-ellipsis`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/i18n-ellipsis.md)
|
|
245
|
-
- The bundled `eslint-plugin-react` dependency has been updated from requiring `^7.14.3` to requiring `^7.19.0` ([#21424](https://github.com/WordPress/gutenberg/pull/21424)).
|
|
246
|
-
|
|
247
|
-
### Bug Fixes
|
|
248
|
-
|
|
249
|
-
- The `@wordpress/valid-sprintf` rule now detects usage of `sprintf` via `i18n.sprintf` (e.g. when using `import * as i18n from '@wordpress/i18n'`).
|
|
250
|
-
- `@wordpress/no-unused-vars-before-return` will correctly consider other unused variables after encountering an instance of an `excludePattern` option exception.
|
|
251
|
-
|
|
252
|
-
## 4.1.0 (2020-04-01)
|
|
253
|
-
|
|
254
|
-
### New Features
|
|
255
|
-
|
|
256
|
-
- The `prefer-const` rule included in the `recommended` and `esnext` rulesets has been relaxed to allow a `let` assignment if any of a [destructuring assignment](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Destructuring_assignment) are reassigned.
|
|
257
|
-
|
|
258
|
-
## 4.0.0 (2020-02-10)
|
|
259
|
-
|
|
260
|
-
### Breaking Changes
|
|
261
|
-
|
|
262
|
-
- The `recommended` ruleset checks again code formatting (whitespace, indenting, etc.). These rules are now enforced by Prettier itself through a plugin that diffs the code with its formatted output and reports the differences as lint errors. `eslint-plugin-prettier` was chosen over options like `prettier-eslint` because we don't run `eslint --fix` in hooks as we'd rather leave certain linting errors to be resolved or ignored at the author's discretion. We also don't apply any additional formatting with `eslint` over `prettier`, so the overhead would be unnecessary. `eslint-plugin-prettier` was chosen over options like `prettier --check` because it's nice to see format errors as you type as it leads you to write code with a more optimal auto-formatted output and it avoids issues like comment directives being moved out of place by `prettier` and the author not realizing it.
|
|
263
|
-
|
|
264
|
-
## 3.4.1 (2020-02-04)
|
|
265
|
-
|
|
266
|
-
### Bug Fix
|
|
267
|
-
|
|
268
|
-
- Removed `plugin:prettier/recommended` from `recommended` ruleset as it introduces breaking changes.
|
|
269
|
-
|
|
270
|
-
## 3.4.0 (2020-02-04)
|
|
271
|
-
|
|
272
|
-
### New Features
|
|
273
|
-
|
|
274
|
-
- The `recommended` ruleset no longer enables rules that check code formatting (whitespace, indenting, etc.) and that could conflict with Prettier.
|
|
275
|
-
- There is a new `recommended-with-formatting` ruleset that has the code formatting rules still enabled, for projects that want to opt out from Prettier and continue checking code formatting with ESLint.
|
|
276
|
-
|
|
277
|
-
## 3.3.0 (2019-12-19)
|
|
278
|
-
|
|
279
|
-
### Bug Fixes
|
|
280
|
-
|
|
281
|
-
- The React ruleset now correctly references the WordPress ESLint plugin, resolving an error about an unfound rule.
|
|
282
|
-
|
|
283
|
-
## 3.0.0 (2019-08-29)
|
|
284
|
-
|
|
285
|
-
### Breaking Changes
|
|
286
|
-
|
|
287
|
-
- The [`@wordpress/no-unused-vars-before-return` rule](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/no-unused-vars-before-return.md) has been improved to exempt object destructuring only if destructuring to more than one property.
|
|
288
|
-
- Stricter JSDoc linting using [`eslint-plugin-jsdoc`](https://github.com/gajus/eslint-plugin-jsdoc).
|
|
289
|
-
- Stricter validation enabled for test files only using new `test-e2e` and `test-unit` rulesets.
|
|
290
|
-
|
|
291
|
-
### New Features
|
|
292
|
-
|
|
293
|
-
- New Rule: [`@wordpress/no-unguarded-get-range-at`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/no-unguarded-get-range-at.md)
|
|
294
|
-
- Enable `wp` global by default in the `recommended` config.
|
|
295
|
-
- New ruleset `test-e2e` added for end-to-end tests validation.
|
|
296
|
-
- New ruleset `test-unit` added for unit tests validation.
|
|
297
|
-
|
|
298
|
-
### Enhancements
|
|
299
|
-
|
|
300
|
-
- Remove `@wordpress/dependency-group` and `@wordpress/gutenberg-phase` rules from the `custom` and `recommended` configs and leave them as opt-in features.
|
|
301
|
-
|
|
302
|
-
## 2.4.0 (2019-08-05)
|
|
303
|
-
|
|
304
|
-
### New Features
|
|
305
|
-
|
|
306
|
-
- [`@wordpress/no-unused-vars-before-return`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/no-unused-vars-before-return.md) now supports an `excludePattern` option to exempt function calls by name.
|
|
307
|
-
|
|
308
|
-
### Improvements
|
|
309
|
-
|
|
310
|
-
- The recommended `react` configuration specifies an option to [`@wordpress/no-unused-vars-before-return`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/no-unused-vars-before-return.md) to exempt React hooks usage, by convention of hooks beginning with "use" prefix.
|
|
311
|
-
- The plugin now uses [`eslint-plugin-jsdoc`](https://github.com/gajus/eslint-plugin-jsdoc), rather than the `valid-jsdoc` rule, for more reliable linting of JSDoc blocks.
|
|
312
|
-
|
|
313
|
-
## 2.3.0 (2019-06-12)
|
|
314
|
-
|
|
315
|
-
### Bug Fix
|
|
316
|
-
|
|
317
|
-
- Fixed custom regular expression for the `no-restricted-syntax` rule enforcing translate function arguments. [#15839](https://github.com/WordPress/gutenberg/pull/15839).
|
|
318
|
-
- Fixed arguments checking of `_nx` for the `no-restricted-syntax` rule enforcing translate function arguments. [#15839](https://github.com/WordPress/gutenberg/pull/15839).
|
|
319
|
-
- Fixed false positive with `react-no-unsafe-timeout` which would wrongly flag errors when assigning `setTimeout` result to a variable (for example, in a `useEffect` hook).
|
|
320
|
-
|
|
321
|
-
## 2.2.0 (2019-05-21)
|
|
322
|
-
|
|
323
|
-
### New Features
|
|
324
|
-
|
|
325
|
-
- New Rule: [`@wordpress/react-no-unsafe-timeout`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/react-no-unsafe-timeout.md)
|
|
326
|
-
- Add [React Hooks Rules](https://reactjs.org/docs/hooks-rules.html) config.
|
|
327
|
-
|
|
328
|
-
## 2.1.0 (2019-03-20)
|
|
329
|
-
|
|
330
|
-
### New Features
|
|
331
|
-
|
|
332
|
-
- The bundled `eslint-plugin-jsx-a11y` dependency has been updated from requiring `^6.0.2` to requiring `^6.2.1` (see new features added in [6.2.0](https://github.com/evcohen/eslint-plugin-jsx-a11y/releases/tag/v6.2.0) and [6.1.0](https://github.com/evcohen/eslint-plugin-jsx-a11y/releases/tag/v6.1.0)).
|
|
333
|
-
- The bundled `eslint-plugin-react` dependency has been updated from requiring `7.7.0` to requiring `^7.12.4` (see new features added in [7.12.0](https://github.com/yannickcr/eslint-plugin-react/releases/tag/v7.12.0), [7.11.0](https://github.com/yannickcr/eslint-plugin-react/releases/tag/v7.11.0), [7.10.0](https://github.com/yannickcr/eslint-plugin-react/releases/tag/v7.10.0), [7.9.0](https://github.com/yannickcr/eslint-plugin-react/releases/tag/v7.9.0) and [7.8.0](https://github.com/yannickcr/eslint-plugin-react/releases/tag/v7.8.0)).
|
|
334
|
-
|
|
335
|
-
## 2.0.0 (2019-03-06)
|
|
336
|
-
|
|
337
|
-
### Breaking Changes
|
|
338
|
-
|
|
339
|
-
- The `esnext` and `recommended` rulesets now enforce [`object-shorthand`](https://eslint.org/docs/rules/object-shorthand)
|
|
340
|
-
- The `es5` and `recommended` rulesets now enforce [`array-callback-return`](https://eslint.org/docs/rules/array-callback-return)
|
|
341
|
-
|
|
342
|
-
### New Features
|
|
343
|
-
|
|
344
|
-
- New Rule: [`@wordpress/no-unused-vars-before-return`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/no-unused-vars-before-return.md)
|
|
345
|
-
- New Rule: [`@wordpress/dependency-group`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/dependency-group.md)
|
|
346
|
-
- New Rule: [`@wordpress/valid-sprintf`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/valid-sprintf.md)
|
|
347
|
-
- New Rule: [`@wordpress/gutenberg-phase`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/gutenberg-phase.md)
|
|
348
|
-
- New Rule: [`@wordpress/no-base-control-with-label-without-id`](https://github.com/WordPress/gutenberg/blob/HEAD/packages/eslint-plugin/docs/rules/no-base-control-with-label-without-id.md)
|
|
349
|
-
|
|
350
|
-
## 1.0.0 (2018-12-12)
|
|
351
|
-
|
|
352
|
-
### New Features
|
|
353
|
-
|
|
354
|
-
- Initial release.
|