From 7cc41c99534457b2a1eaa8588b8076d8cb91bf38 Mon Sep 17 00:00:00 2001 From: Yosuke Ota Date: Sun, 7 Jun 2020 19:26:45 +0900 Subject: [PATCH] Add `vue/func-call-spacing` rule (#1201) * Add `vue/func-call-spacing` rule * fix * fixed --- docs/rules/README.md | 1 + docs/rules/func-call-spacing.md | 25 ++++++++ lib/configs/no-layout-rules.js | 1 + lib/index.js | 1 + lib/rules/func-call-spacing.js | 11 ++++ tests/lib/rules/func-call-spacing.js | 85 ++++++++++++++++++++++++++++ 6 files changed, 124 insertions(+) create mode 100644 docs/rules/func-call-spacing.md create mode 100644 lib/rules/func-call-spacing.js create mode 100644 tests/lib/rules/func-call-spacing.js diff --git a/docs/rules/README.md b/docs/rules/README.md index 261eed05c..1fe658682 100644 --- a/docs/rules/README.md +++ b/docs/rules/README.md @@ -322,6 +322,7 @@ The following rules extend the rules provided by ESLint itself and apply them to | [vue/dot-location](./dot-location.md) | enforce consistent newlines before and after dots | :wrench: | | [vue/dot-notation](./dot-notation.md) | enforce dot notation whenever possible | :wrench: | | [vue/eqeqeq](./eqeqeq.md) | require the use of `===` and `!==` | :wrench: | +| [vue/func-call-spacing](./func-call-spacing.md) | require or disallow spacing between function identifiers and their invocations | :wrench: | | [vue/key-spacing](./key-spacing.md) | enforce consistent spacing between keys and values in object literal properties | :wrench: | | [vue/keyword-spacing](./keyword-spacing.md) | enforce consistent spacing before and after keywords | :wrench: | | [vue/max-len](./max-len.md) | enforce a maximum line length | | diff --git a/docs/rules/func-call-spacing.md b/docs/rules/func-call-spacing.md new file mode 100644 index 000000000..41af5a45a --- /dev/null +++ b/docs/rules/func-call-spacing.md @@ -0,0 +1,25 @@ +--- +pageClass: rule-details +sidebarDepth: 0 +title: vue/func-call-spacing +description: require or disallow spacing between function identifiers and their invocations +--- +# vue/func-call-spacing +> require or disallow spacing between function identifiers and their invocations + +- :wrench: The `--fix` option on the [command line](https://eslint.org/docs/user-guide/command-line-interface#fixing-problems) can automatically fix some of the problems reported by this rule. + +This rule is the same rule as core [func-call-spacing] rule but it applies to the expressions in `