Preserve quotes for TSMethodSignature nodes named new (#19621)

This commit is contained in:
Konv Suu authored and GitHub committed 2026-07-14 17:33:39 +08:00
1 parent c4174396c5
commit 5f2c401ab0
4 files changed
+122

No files matched your search

+19
View File
@@ -0,0 +1,19 @@
#### Preserve quotes for methods named `new` (#19621 by @kovsu)
<!-- prettier-ignore -->
```tsx
// Input
interface Container {
"new"(id: string): number;
}
// Prettier stable
interface Container {
new(id: string): number;
}
// Prettier main
interface Container {
"new"(id: string): number;
}
```