A conventional way to bind logic to DOM elements