[api-extractor] Upgrade API Extractor's compiler to 5.9.2
Summary
I'm bundling a set of d.ts files and getting the following error:
Symbol not found for identifier: ...
I found this old issue where the same problem was caused by a version mismatch: https://github.com/microsoft/rushstack/issues/1370
I also get this message in the console:
Analysis will use the bundled TypeScript version 5.8.2
*** The target project appears to use TypeScript 5.9.2 which is newer than the bundled compiler engine; consider upgrading API Extractor.
I tried using typescriptCompilerFolder pointing to my compiler directory with no luck.
As specified in the docs, since my toolchain uses TS 5.9.2 and the latest version of api-extractor uses 5.8.2, I'm requesting if you can upgrade to TS 5.9.2 because I believe the error I'm getting is related to this version mismatch.
Repro steps
Not sure, but maybe having a Symbol exported in a TS file compiled with the newer compiler version is what's causing the issue.
Standard questions
Please answer these questions to help us investigate your issue more quickly:
| Question | Answer |
|---|---|
@microsoft/api-extractor version? |
7.52.11 |
| Operating system? | Mac |
| API Extractor scenario? | d.ts |
| Would you consider contributing a PR? | Yes |
| TypeScript compiler version? | Mine? 5.9.2 |
Node.js version (node -v)? |
22.14 |
It seems this is a recurring issue. I'm creating a documentation automation tool that uses api-extractor and I don't control the TS version of the end user's project.
Isn't there a way to set the version of tsc via config (at least within a reasonable range) to avoid these issues?