-
-
Notifications
You must be signed in to change notification settings - Fork 32.3k
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
[Popper] Update TypeScript definitions #12161
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.
Thanks for cleaning that up.
anchorEl?: HTMLElement | ((element: HTMLElement) => HTMLElement); | ||
children: () => React.ReactElement<any> | React.ReactElement<any>; | ||
transition?: boolean; | ||
anchorEl?: null | HTMLElement | ((element: HTMLElement) => HTMLElement); |
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.
How is ?
not enough?
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.
With strictNullChecks
or strict
mode turned on, ?
only allows for passing undefined
, but passing null
does work too.
In reality, any developer using strict
should be capable of figuring out that they can just use undefined
but documentation example was using null
so dunno thought I'd add it.
Not really important.
@Slessi Thank you |
transition
propnull
as option toanchorEl
(strictNullChecks
will complain thatnull
is not valid)childProps
def forchildren