Hi suppose I have a button with id form-submit
and I have the following function in my OCaml file:
let () =
let form_submit = Dom_html.getElementById "form-submit" in
...
What is the right way to add a on_click method to the button? Should I just do something like this?
form_submit##onclick <- ...
But whats the type of the handler function? I cannot find it in the documentation.