Skip to content
This repository has been archived by the owner on Aug 31, 2023. It is now read-only.

ConstructorSignatureMembers: Add a space between the new keyword and parameters #2419

Closed
Tracked by #2403
MichaReiser opened this issue Apr 13, 2022 · 0 comments · Fixed by #2507
Closed
Tracked by #2403

ConstructorSignatureMembers: Add a space between the new keyword and parameters #2419

MichaReiser opened this issue Apr 13, 2022 · 0 comments · Fixed by #2507
Assignees
Labels
A-Formatter Area: formatter good first issue Good for newcomers

Comments

@MichaReiser
Copy link
Contributor

MichaReiser commented Apr 13, 2022

Prettier inserts a space between the new keyword and the parameters for ConstructorSignatureMembers but Rome does not Playground.

Input

type WithNew = { new(s: string): any };

interface X { 
  new(s: string): any; 
}

Prettier

type WithNew = { new (s: string): any };

interface X {
  new (s: string): any;
}

Rome

type WithNew = { new(s: string): any };

interface X { new(s: string): any }

Expected

Rome to match Prettier's formatting (the formatting of interface members is part of another issue).

@MichaReiser MichaReiser changed the title ConstructorSignatureMembers: Add space between the new keyword and parameters ConstructorSignatureMembers: Add a space between the new keyword and parameters Apr 13, 2022
@MichaReiser MichaReiser added good first issue Good for newcomers A-Formatter Area: formatter labels Apr 13, 2022
@ematipico ematipico self-assigned this Apr 27, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A-Formatter Area: formatter good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants