JavaScript in button hold question

Would like to make a button that, whenn clicked and keep pressed, wil result in a number going up. Releasing the button would have to stop the action. i guess JS would be the only solution? But how?