onSubmit Hook

There you go, I've create a configurable onSubmit hook. I'm not sure about the diff for the `"default"` key though. 
My bad, this is an old comment. It shoudn't be there.