Skip to content

[no-large-snapshots] Unexpected rules are being enabled for snap files #1559

Open
@asapach

Description

@asapach

Since snapshot processor has been removed in #1532 (v28.0), we see that unexpected rules are now being enabled for .snap files from ESLint config, which didn't previously run. Because snap files are generated, it doesn't generally make sense to run the same rule set as the rest of the source code, and disabling such rules via overrides seems like overhead.
It would be good to either have an option to restore the previous behavior where only no-large-snapshots rule was enabled for snapshots, or to minimize the overhead.

Steps to reproduce:

  1. Follow the guide in no-large-snapshots docs
  2. Enable more rules in your ESLint config that might clash with snapshots, e.g. no-irregular-whitespace
  3. See that ESLint now produces more errors than it did prior to v28.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions