Skip to content
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

Set indeterminate prop directly, fixes #128 #129

Merged
merged 1 commit into from
Apr 25, 2018

Conversation

gmaclennan
Copy link
Contributor

<input type="checkbox" indeterminate="indeterminate">

does not work currently, because indeterminate needs to be set directly instead of with el.setAttribute().

This should make things work as expected.

@goto-bus-stop goto-bus-stop merged commit 3e79599 into choojs:master Apr 25, 2018
@goto-bus-stop
Copy link
Member

goto-bus-stop commented Apr 25, 2018

Perrrfect, thank you! 📦 1.2.4

@gmaclennan
Copy link
Contributor Author

@goto-bus-stop Having implemented this I see some drawbacks... this will not work for server-side rendering - there is simply no way to make it work. It also does not work with nanomorph or morphdom. I'm not sure what is needed to make it work. I found this react thread discussing this same issue where essentially they decided not to support it because of all the edge cases: facebook/react#1798

@goto-bus-stop
Copy link
Member

Hmm, I see—we probably need to specialcase it in the updateInput function in nanomorph.

For server side render I suppose we will have to wait for the client side to render once to get the indeterminate property set, but having the attribute there probably doesn't hurt? If it starts to work once nanomorph runs I think it's OK to ignore SSR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants