-
Notifications
You must be signed in to change notification settings - Fork 245
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for Typescript 4.x #3609
Comments
There was an attempt with #1940 but it never was merged due to potential breaking changes. I really hope it would be done anyway at some time as this is making things tricky very often, and the situation won't improve |
There's a proposal out with aws/aws-cdk-rfcs#373 to fix this, but I'm not sure what it's present status is. |
- version pin @types/prettier DefinitelyTyped/DefinitelyTyped#60314 - upgrade npm-check-updates raineorshine/npm-check-updates#1145 and projen/projen#1963 - upgrade aws-cdk-lib 2.32.0 https://github.com/aws/aws-cdk/releases/tag/v2.32.0 - use projenrc ts - upgrade jsii 1.62.0 aws/jsii#3609 - upgrade jsii-docgen
- version pin @types/prettier DefinitelyTyped/DefinitelyTyped#60314 - upgrade npm-check-updates raineorshine/npm-check-updates#1145 and projen/projen#1963 - upgrade aws-cdk-lib 2.32.0 https://github.com/aws/aws-cdk/releases/tag/v2.32.0 - use projenrc ts - upgrade jsii 1.62.0 aws/jsii#3609 - upgrade jsii-docgen
@RichiCoder1 you're correct, this is the current plan. I've investigated doing a "bring your own typescript" with adapters but it turns out to be nearly impossible to do without creating a maintenance nightmare. The RFC still stands as the best plan I have so far, and I would like to implement that sooner rather than later (but so far received very little traction/interest). |
Given that DefinitelyTyped just dropped support for TS versions <4.x (as they only support TS versions that are less than two years old), this issue seems to become a bit more pressing 😅 |
We are actively working on RFC 373, and plan to have preview releases out as soon as possible. |
That's awesome! I'm sure the team is aware, but hopefully some of the insight from that work can help with the now impending TS 5 release coming out this quarter. I don't think there's an urgency, but still! |
So I guess with jsii@^5 typescript 5 is now supported and this issue is resolved? CDK ^2.72 uses migrated to use jsii@~5 and ts 5 |
This issue is now closed. Comments on closed issues are hard for our team to see. |
Yes, modern TS is fully supported now. |
Describe the feature
I am told that the reason that AWS CDK depends on Typescript 3.9 is beacuse of jsii in #18743, I am now stuck in a situation where cdk cannot use typescript above 3.9 and tsc cannot use typescript below 4.2 (due to @types issue 60310). While that might get reverted eventually, it points to the long term unsustainable nature of requiring a version of a key library that is both an entire major version behind and 7 overall releases behind.
Use Case
Compatibility: I cannot run cdk after running npm up at all because @types/prettier automatically upgrades unless manually pinned (which I did not know to do), nor can I initialize a new cdk workspace with typescript because the install grabs the latest version of @types/prettier which won't work with the required version of typescript.
Proposed Solution
Upgrade the supported version of typescript.
Other Information
No response
Acknowledgements
CDK version used
2.28.1 (build d035432)
Environment details (OS name and version, etc.)
Ubuntu 20 LTS with node 16 from https://nodesource.com/, but also tested and verified on OSX 12.2 with node from homebrew
The text was updated successfully, but these errors were encountered: