Skip to content

fix: bracePosition maintain interaction with classes with a type literal - #902

Merged
dsherret merged 1 commit into
dprint:mainfrom
thristhart:fix/membered-body-open-brace-after-type-literal
Nov 6, 2026
Merged

dsherret merged 1 commit into
dprint:mainfrom
thristhart:fix/membered-body-open-brace-after-type-literal

Conversation

@thristhart

Copy link
Copy Markdown
Contributor

prior to this:

    class A extends B<{}>
    {

became

    class A extends B<{}> {

because the type literal's { was treated as the opening brace

prior to this:
```ts
    class A extends B<{}>
    {
```
became
```
    class A extends B<{}> {
```

because the type literal's `{` was treated as the opening brace

@dsherret dsherret left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch. Thanks!

@dsherret dsherret changed the title fix bracePosition maintain interaction with classes with a type literal fix: bracePosition maintain interaction with classes with a type literal Nov 6, 2026
@dsherret
dsherret merged commit b520902 into dprint:main Nov 6, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants