Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix type declarations for typescript <4 #251

Merged
merged 2 commits into from
Dec 3, 2020
Merged

Fix type declarations for typescript <4 #251

merged 2 commits into from
Dec 3, 2020

Conversation

mmkal
Copy link
Owner

@mmkal mmkal commented Nov 25, 2020

Fixes #250

ts-ignore isn't included in d.ts files, so typescript versions that don't support rest elements. This works around by using sed to re-add the // @ts-ignore directive. Probably a better solution would be to use typesVersions, but as far as I can tell that would mean compiling two completely different versions of the types, which seems like overkill for this one small utility that can just use a conditional.

@mmkal mmkal merged commit 98a0ba7 into master Dec 3, 2020
@mmkal mmkal deleted the ts-ignore-dts branch December 3, 2020 22:42
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Multi Type definition issue
1 participant