Closed
Description
Bug Report
transpileModule fails with TS5104 error when verbatimModuleSyntax: true
"TS5104: Option 'isolatedModules' is redundant and cannot be specified with option 'verbatimModuleSyntax'"
Why? According to those comments (and source code)
TypeScript/src/services/transpile.ts
Lines 49 to 55 in 746a6fe
it unconditionally adds 'isolatedModules: true' to compiler options. And fails because verbatimModuleSyntax is not compatible with isolatedModules.
🔎 Search Terms
verbatimModuleSyntax
isolatedModules
transpileModule
🕗 Version & Regression Information
5.0.1-rc
5.1.0-dev.20230307
- I was unable to test this on prior versions because verbatimModuleSyntax is not available in 4.x
⏯ Playground Link
N/A
💻 Code
transpileModule('any valid code', {compilerOptions: {verbatimModuleSyntax: true, /* common options like module, etc. */}})
🙁 Actual behavior
TS5104: Option 'isolatedModules' is redundant and cannot be specified with option 'verbatimModuleSyntax'
🙂 Expected behavior
No errors