The buttons are useful but not necessarily relevant to every user. We would like to hide (but not remove) the buttons and delegate the change of an input to the click of the button.
When JavaScript is active we would like to remove the button from the view but trigger its click action when the input has been changed.
- event delegation
- jQuery DOM manipulation
on Codepen
- Task – removing the buttons (same as the solution from lesson 3)
- Solution