Skip to content

Drop TS 4 support and add const P extends for getIn method types #2072

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

Merged
merged 1 commit into from
Mar 19, 2025

Conversation

jdeniau
Copy link
Member

@jdeniau jdeniau commented Mar 19, 2025

Use const type parameters for getIn path retrieval.

This feature has been introduced in TS 5.0, which is more than two years old now. This PR drops support for TS < 5.0.

@@ -66,7 +66,7 @@ jobs:
- run: npm ci
- run: npm run build
- run: npm run test:unit
- run: npm run test:types -- --target 4.5,5.0,current
- run: npm run test:types -- --target 5.0,current
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! To draw your attention, tstyche@3.1.1 and above makes it possible to test agains a range of versions:

Suggested change
- run: npm run test:types -- --target 5.0,current
- run: npm run test:types -- --target '>=5.0'

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, but doing that the tests ran 5 times slower.
I do not know if it's worth it for now (but I do keep that in mind)

@jdeniau jdeniau merged commit 46f73e3 into 6.x Mar 19, 2025
5 checks passed
@jdeniau jdeniau deleted the drop-ts-support branch March 19, 2025 20:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants