Skip to content

Improve typing #26

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
Aug 16, 2023
Merged

Improve typing #26

merged 1 commit into from
Aug 16, 2023

Conversation

UNIDY2002
Copy link
Contributor

  • Use generic to replace string | number
    • Otherwise, when implementing renderItem, users have to explicitly cast data to either string or number even when there is only one possible choice given the specific dataSource
  • Correctly implement type of ref
    • So that ref.current.scrollToTargetIndex can be typed properly

@rheng001 rheng001 added the enhancement New feature or request label Aug 16, 2023
@rheng001 rheng001 merged commit e8c06b1 into rheng001:master Aug 16, 2023
@rheng001 rheng001 added the merged Has been merged and fixed label Aug 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request merged Has been merged and fixed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants