-
Notifications
You must be signed in to change notification settings - Fork 216
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
autoFocus prop has wrong capitalization vs React #165
Comments
This gets rid of the warning in React 15.2+ Note that `autofocus` needs stripping too, but if you implement elementalui#165 this is not necessary.
In fact, since the components just pass other props, |
React does the right thing with it and Elemental-UI already supports it: elementalui/elemental#165 This removes stateful code. It also works in the Modal because the Modal will not render its contents until it opens: https://github.com/elementalui/elemental/blob/620efc246d7f5fd123a2af3fa7f07bf4e745a0fb/src/components/Modal.js#L127-L128
Note that the this.focus() calls on componentDidMount are now not On Tue, Jul 26, 2016, 5:08 AM Jed Watson [email protected] wrote:
|
This gets rid of the warning in React 15.2+ Note that `autofocus` needs stripping too, but if you implement elementalui#165 this is not necessary. git-svn-id: https://github.com/elementalui/elemental.git@738 773dd515-ab26-cda1-e266-ce57b7db7bff
git-svn-id: https://github.com/elementalui/elemental.git@744 773dd515-ab26-cda1-e266-ce57b7db7bff
All through the code,
autofocus
is used, however React writes it asautoFocus
, and that causes mistakes. Please use the more commonautoFocus
spelling.See also #95 which partially fixes it (slightly breaking the API in the process).
The text was updated successfully, but these errors were encountered: