-
Notifications
You must be signed in to change notification settings - Fork 558
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
Add Typescript definitions #225
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
blurType: 'xlight' | 'light' | 'dark' | ||
// tvOS only | ||
| 'extraDark' | 'regular' | 'prominent'; | ||
blurAmount?: number; // 0 - 100 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we be more precise about the range?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @Kureev, the only possible way to do it currently would be to have a enum like:
blurAmount?: 0 | 1 | 2 | 3 | ... | 99 | 100;
This issue on Typescript is exactly what we are looking for, but it looks like there is currently no clean way to do it, appart using an enum microsoft/TypeScript#15480 👀
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, got it! Thanks for the insight! Then I think it isn't a problem
Hi @ahanriat! Nice! Thank you for the PR! I have one question regarding the range of the |
Fix typescript definition
Thank you for this awesome contribution 🙌 |
blurType: 'xlight' | 'light' | 'dark' | ||
// tvOS only | ||
| 'extraDark' | 'regular' | 'prominent'; | ||
blurAmount?: number; // 0 - 100 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't viewRef be in there as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@arnibarnason doesn't the extends React.Component
does this?
Hi Guys 👋
Just a quick PR to add Typescript definitions.
Hope you'll like it !
Cheers