The default type of a `<button>` is "submit". I suggest you to add a `type="button"` attribute to the element.