Content-Length: 305120 | pFad | https://github.com/typescript-eslint/typescript-eslint/commit/#start-of-content

687D488E fix: disallow extra properties in rule options (#11397) · typescript-eslint/typescript-eslint@5ec8c58 · GitHub
Skip to content

Commit 5ec8c58

Browse files
authored
fix: disallow extra properties in rule options (#11397)
* fix: disallow extra properties in rule options * chore: regenerate schema snapshots * fix: linter errors
1 parent ca00714 commit 5ec8c58

File tree

4 files changed

+4
-2
lines changed

4 files changed

+4
-2
lines changed

packages/eslint-plugin/src/rules/prefer-destructuring.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ const schema: readonly JSONSchema4[] = [
5252
},
5353
{
5454
type: 'object',
55+
additionalProperties: false,
5556
properties: {
5657
enforceForDeclarationWithTypeAnnotation: {
5758
type: 'boolean',

packages/eslint-plugin/src/rules/prefer-nullish-coalescing.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,7 @@ export default createRule<Options, MessageIds>({
123123
oneOf: [
124124
{
125125
type: 'object',
126+
additionalProperties: false,
126127
description: 'Which primitives types may be ignored.',
127128
properties: {
128129
bigint: {

packages/eslint-plugin/tests/schema-snapshots/prefer-destructuring.shot

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/eslint-plugin/tests/schema-snapshots/prefer-nullish-coalescing.shot

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/typescript-eslint/typescript-eslint/commit/#start-of-content

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy