Skip to content

Commit dc56c56

Browse files
shulaodaBoshen
andauthored
feat: deserialize preserve_value_imports and imports_not_used_as_values from compilerOptions (#457)
Related to rolldown/rolldown#4174 Align with [rolldown-vite](https://github.com/vitejs/rolldown-vite/blob/da2cc9626520e2556c0dd0b5273dbd1aa4a5a7c8/packages/vite/src/node/plugins/oxc.ts#L146-L190) In fact, `preserveValueImports` and `importsNotUsedAsValues` have been deprecated and replaced by `verbatimModuleSyntax`. However, for compatibility and alignment with `rolldown-vite`, I had to suggest adding them. --------- Co-authored-by: Boshen <[email protected]>
1 parent 9573ddd commit dc56c56

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/tsconfig_serde.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,12 @@ pub struct CompilerOptionsSerde {
137137
/// <https://www.typescriptlang.org/tsconfig/#verbatimModuleSyntax>
138138
pub verbatim_module_syntax: Option<bool>,
139139

140+
/// <https://www.typescriptlang.org/tsconfig/#preserveValueImports>
141+
pub preserve_value_imports: Option<bool>,
142+
143+
/// <https://www.typescriptlang.org/tsconfig/#importsNotUsedAsValues>
144+
pub imports_not_used_as_values: Option<String>,
145+
140146
/// <https://www.typescriptlang.org/tsconfig/#target>
141147
pub target: Option<String>,
142148
}

0 commit comments

Comments
 (0)