Skip to content

Add option to ignore spread operator in sort-default-props #2178

Closed
@VincentLanglet

Description

@VincentLanglet

With foo = { bar: baz }.

{ ...foo, bar } = { bar }

And

{ bar, ...for } = { baz }

So I think, an option to ignore spread operator in sort default props will be great.
Correct example

{ a: 'a', c: 'c', ...foo, b: 'b', d: 'd' }

Incorrect example

{ a: 'a', ...foo, c: 'c', b: 'b', d: 'd' }

Plus, it allow to develop a fixer (asked here) without breaking the code.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions