Skip to content

Ugly formatting for class implements with long type parameters #8943

@sosukesuzuki

Description

@sosukesuzuki

This is regression on master. I found this when work on #8941.
Prettier pr-8931(Current master)
Playground link

--parser typescript

Input:

class ReallyReallyLongName2<
  TypeArgumentNumberOne,
  TypeArgumentNumberTwo,
  TypeArgumentNumberThree
> implements BaseInterface {}

Output:

class ReallyReallyLongName2<
    TypeArgumentNumberOne,
    TypeArgumentNumberTwo,
    TypeArgumentNumberThree
  >
  implements BaseInterface {}

Expected behavior(2.0.5 output):

class ReallyReallyLongName2<
  TypeArgumentNumberOne,
  TypeArgumentNumberTwo,
  TypeArgumentNumberThree
> implements BaseInterface {}

Metadata

Metadata

Assignees

Labels

lang:typescriptIssues affecting TypeScript-specific constructs (not general JS issues)locked-due-to-inactivityPlease open a new issue and fill out the template instead of commenting.

Type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions