]> git.proxmox.com Git - pve-eslint.git/commitdiff
rules: dot-location: set location parameter to property
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Thu, 9 Apr 2020 16:29:46 +0000 (18:29 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Thu, 9 Apr 2020 16:30:40 +0000 (18:30 +0200)
who the heck makes the following syntax the default:
> foo.
>    bar().
>    baz();

So let's enforce the right thing™ and enforce the dot sticking to the
property, not the object, i.e.:

> foo
>    .bar().
>    .baz();

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
src/app.js

index c00079ad1b03da8669aaed777ecd7bfe4ec195ca..c01130a9ea7e1649465e08135ffa24b99d10e0db 100644 (file)
@@ -120,7 +120,7 @@ const defaultConfig = {
        "block-scoped-var": "error",
        "consistent-return": "error",
        "curly": ["error", "multi-line"],
-       "dot-location": "error",
+       "dot-location": ["error", "property"],
        "dot-notation": "error",
        "eqeqeq": "error",
        "grouped-accessor-pairs": "error",