Skip to content

Add a test for class superClass #18791

@fisker

Description

@fisker

Prettier 3.8.1
Playground link

--parser typescript

Input:

class A extends (B<T>)
{}

class A extends B<T>
{}

Output:

class A extends B<T> {}

class A extends B<T> {}

Expected output:

Why?

I think they are the same, but they have different AST, better to have a test for it. Maybe we still need #18728 when massaging AST.

Metadata

Metadata

Assignees

No one assigned

    Labels

    lang:typescriptIssues affecting TypeScript-specific constructs (not general JS issues)

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions