fix(unstable): Missing PrivateIdentifier type for PropertyDefinition key (#28358)

The `PropertyDefinition` node also allows `PrivateIdentifier` as a type
for the `key`. Example:

```ts
class Foo {
  #foo = 2;
}
```

Fixes one issue reported in
https://github.com/denoland/deno/issues/28355
This commit is contained in:
Marvin Hagemeister 2025-03-03 11:03:06 +01:00 committed by GitHub
parent 287bde1f72
commit 62bc07884b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1946,7 +1946,12 @@ declare namespace Deno {
static: boolean;
accessibility: Accessibility | undefined;
decorators: Decorator[];
key: Expression | Identifier | NumberLiteral | StringLiteral;
key:
| Expression
| Identifier
| NumberLiteral
| StringLiteral
| PrivateIdentifier;
value: Expression | null;
typeAnnotation: TSTypeAnnotation | undefined;
}