Skip to content
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

Update get.d.ts for TS 4.7 #388

Merged
merged 2 commits into from
Mar 31, 2022
Merged

Conversation

weswigham
Copy link
Contributor

Callers of WithStringKeys pass in an unconstrained type parameter, and StringKeyOf uses an unconstrained type parameter, so WithStringKeys should handle an unconstrained type parameter. TS 4.7 calls out this inconsistency.

weswigham and others added 2 commits March 30, 2022 12:41
Callers of `WithStringKeys` pass in an unconstrained type parameter, and `StringKeyOf` uses an unconstrained type parameter, so `WithStringKeys` should handle an unconstrained type parameter. TS 4.7 calls out this inconsistency.
@sindresorhus sindresorhus merged commit 6c7ac47 into sindresorhus:main Mar 31, 2022
@sindresorhus
Copy link
Owner

Thanks :)

sandersn added a commit to sandersn/electron-store that referenced this pull request Apr 20, 2022
Options's type parameter is passed to conf's Options type, which
requires is constrained to `Record<string, any>`. Typescript 4.7 will
properly check this constraint where it didn't before.

Fixes sindresorhus#222

Depends on fixes: sindresorhus/type-fest#388 and sindresorhus/conf#163
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