Skip to content

feat: repeated keys #842

Description

@Malix-Labs

Is your feature request related to a problem? Please describe.

Currently, there is no report of repeated keys

e.g.

{
  a.b = true;
  a.c = true;
  a = { d = true; };
  a = {
    e.f = true;
    e.g = true;
  };
}

Which, grouped, would be

{
  a = {
    b = true;
    c = true;
    d = true;
    e = { 
      f = true;
      g = true;
    };
  };
}

Describe the solution you'd like

Raising a report for repeated keys

Taking in its scope only the selection, or otherwise the current file / module

The linked code action fix for it would be #831

Describe alternatives you've considered

statix

statix list
"W20 repeated_keys"

Image

Additional context

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions