From d2809b52a683d9bdda0a0d6c467dac1fea29f9e3 Mon Sep 17 00:00:00 2001 From: Jake Ob Date: Wed, 25 Aug 2021 12:45:06 +0300 Subject: [PATCH 1/2] Docs: Make clear how rule options are overridden (fixes #14962) --- docs/user-guide/configuring/configuration-files.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/user-guide/configuring/configuration-files.md b/docs/user-guide/configuring/configuration-files.md index 244fb0e9855..d5158283d73 100644 --- a/docs/user-guide/configuring/configuration-files.md +++ b/docs/user-guide/configuring/configuration-files.md @@ -192,6 +192,10 @@ The `rules` property can do any of the following to extend (or override) the set * Base config: `"quotes": ["error", "single", "avoid-escape"]` * Derived config: `"quotes": ["error", "single"]` * Resulting actual config: `"quotes": ["error", "single"]` +* override options for rules given as object from base configurations: + * Base config: `'max-lines': ['error', { max: 200, skipBlankLines: true, skipComments: true }]` + * Derived config: `'max-lines': ['error', { max: 100 }]` + * Resulting actual config: `'max-lines': ['error', { max: 100 }]` where `skipBlankLines` and `skipComments` default to `false` ### Using a shareable configuration package From 5904c096efaf6b1e4a6ecca73c3b92af24305839 Mon Sep 17 00:00:00 2001 From: Jake Ob Date: Mon, 30 Aug 2021 11:48:33 +0300 Subject: [PATCH 2/2] Docs: Use always double quotes for uniformity --- docs/user-guide/configuring/configuration-files.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/user-guide/configuring/configuration-files.md b/docs/user-guide/configuring/configuration-files.md index d5158283d73..f4feb2fe25b 100644 --- a/docs/user-guide/configuring/configuration-files.md +++ b/docs/user-guide/configuring/configuration-files.md @@ -193,9 +193,9 @@ The `rules` property can do any of the following to extend (or override) the set * Derived config: `"quotes": ["error", "single"]` * Resulting actual config: `"quotes": ["error", "single"]` * override options for rules given as object from base configurations: - * Base config: `'max-lines': ['error', { max: 200, skipBlankLines: true, skipComments: true }]` - * Derived config: `'max-lines': ['error', { max: 100 }]` - * Resulting actual config: `'max-lines': ['error', { max: 100 }]` where `skipBlankLines` and `skipComments` default to `false` + * Base config: `"max-lines": ["error", { "max": 200, "skipBlankLines": true, "skipComments": true }]` + * Derived config: `"max-lines": ["error", { "max": 100 }]` + * Resulting actual config: `"max-lines": ["error", { "max": 100 }]` where `skipBlankLines` and `skipComments` default to `false` ### Using a shareable configuration package