Skip to content
This repository was archived by the owner on Oct 16, 2024. It is now read-only.
This repository was archived by the owner on Oct 16, 2024. It is now read-only.

Performance issues #44

@thany

Description

@thany

In a rather large project, that unfortunately I'm not at liberty to share, performance of this plugin is a bit dissappointing.

The result of this is not only that it might take a very long time to lint the entire project, but more importantly, in VScode with lint-fixing on save enabled, it will take several seconds for each save action to complete.

I understand it's difficult to get this problem fixed in this particular repository, however, there just might just be a workaround 😎

Inspired on this more generic issue and this preceeding issue, the solution appears to be this piece of VScode configuration:

    "eslint.enable": true,
    "eslint.useESLintClass": true,
    "eslint.codeActionsOnSave.rules": [
        "!deprecation/deprecation",
        "*",
    ],
    "editor.codeActionsOnSave": {
        "source.fixAll": false,
        "source.fixAll.eslint": true
    },

Essentially skipping the deprecation/deprecation rule. This is fine, because the rule only checks code, but doesn't provide fixes, which is exactly the only thing linting on save is good for. The other bits of config are important to get the VScode extension to understand the rules setting in the first place.

Now, I realise that this only fixes it for VScode (well, it does on my machine), so if you enjoy a different editor, you might have to seek out a different solution. However, the above configuration might nudge that search in the right direction. I would not be surprised if eslint plugins for other editors have a similar rules setting to filter certain rules.

And perhaps it's a good idea to list those solutions below, when anyone finds one.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions