From 79438e6dc24735fae1adc98e9a74ab6cecd502de Mon Sep 17 00:00:00 2001 From: Andrew Leung <84608230+SokuRitszZ@users.noreply.github.com> Date: Tue, 2 Jan 2024 10:37:00 +0800 Subject: [PATCH] fix(binding/types): Add type for `decoratorVersion` (#8468) **Description:** Add type hint `"2021-12" | "2023-03` for `jsc.transform.decoratorVersion`. **Related issue:** - Closes #8467 --- packages/types/index.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/types/index.ts b/packages/types/index.ts index c1114b0e749..98340dce966 100644 --- a/packages/types/index.ts +++ b/packages/types/index.ts @@ -764,6 +764,11 @@ export interface TransformConfig { */ decoratorMetadata?: boolean; + /** + * https://swc.rs/docs/configuration/compilation#jsctransformdecoratorversion + */ + decoratorVersion?: "2021-12" | "2022-03"; + treatConstEnumAsEnum?: boolean; useDefineForClassFields?: boolean;