You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a number of checkboxes on a form and wish to set and unset some from JavaScript after the page has loaded.
setting the "checked" property of the Input element in the DOM has no effect.
calling componentHandler.upgradeElement() after setting the checked state has no effect.
I looked at all of the issues tagged for checkbox but did not see a solution. Feels a tad fundamental - I am assuming there are methods to interact with the MDL upgraded HTML objects.
The text was updated successfully, but these errors were encountered:
Thanks @MikeGWem for your solution. I was facing the same issue. I feel there should be a more generic way of doing this and componentHandler.upgradeElement() should ideally do this job.
I have a number of checkboxes on a form and wish to set and unset some from JavaScript after the page has loaded.
setting the "checked" property of the Input element in the DOM has no effect.
calling componentHandler.upgradeElement() after setting the checked state has no effect.
I looked at all of the issues tagged for checkbox but did not see a solution. Feels a tad fundamental - I am assuming there are methods to interact with the MDL upgraded HTML objects.
The text was updated successfully, but these errors were encountered: