diff options
| author | David Sherret <dsherret@users.noreply.github.com> | 2023-09-09 14:03:21 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-09-09 15:03:21 -0400 |
| commit | c228adc27d5b605286d3a9ca924e657308aebb74 (patch) | |
| tree | fdc0e814bdaeceb231565ee8e0324c7447c39212 /cli/tsc/dts/lib.decorators.d.ts | |
| parent | f75a17521df053218c0c2b5fb93c5354f9c8f274 (diff) | |
feat: TypeScript 5.2 (#20425)
Without `using` declarations or decorator metadata (waiting for that in
v8).
Diffstat (limited to 'cli/tsc/dts/lib.decorators.d.ts')
| -rw-r--r-- | cli/tsc/dts/lib.decorators.d.ts | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/cli/tsc/dts/lib.decorators.d.ts b/cli/tsc/dts/lib.decorators.d.ts index 2d2b4ee2a..11a8ca6de 100644 --- a/cli/tsc/dts/lib.decorators.d.ts +++ b/cli/tsc/dts/lib.decorators.d.ts @@ -35,6 +35,11 @@ type DecoratorContext = | ClassMemberDecoratorContext ; +type DecoratorMetadataObject = Record<PropertyKey, unknown> & object; + +type DecoratorMetadata = + typeof globalThis extends { Symbol: { readonly metadata: symbol } } ? DecoratorMetadataObject : DecoratorMetadataObject | undefined; + /** * Context provided to a class decorator. * @template Class The type of the decorated class associated with this context. @@ -66,6 +71,8 @@ interface ClassDecoratorContext< * ``` */ addInitializer(initializer: (this: Class) => void): void; + + readonly metadata: DecoratorMetadata; } /** @@ -130,6 +137,8 @@ interface ClassMethodDecoratorContext< * ``` */ addInitializer(initializer: (this: This) => void): void; + + readonly metadata: DecoratorMetadata; } /** @@ -175,6 +184,8 @@ interface ClassGetterDecoratorContext< * decorating a non-`static` element). */ addInitializer(initializer: (this: This) => void): void; + + readonly metadata: DecoratorMetadata; } /** @@ -220,6 +231,8 @@ interface ClassSetterDecoratorContext< * decorating a non-`static` element). */ addInitializer(initializer: (this: This) => void): void; + + readonly metadata: DecoratorMetadata; } /** @@ -274,6 +287,8 @@ interface ClassAccessorDecoratorContext< * decorating a non-`static` element). */ addInitializer(initializer: (this: This) => void): void; + + readonly metadata: DecoratorMetadata; } /** @@ -369,4 +384,6 @@ interface ClassFieldDecoratorContext< * decorating a non-`static` element). */ addInitializer(initializer: (this: This) => void): void; + + readonly metadata: DecoratorMetadata; } |
