0👍
✅
You should prevent submit and post data using axios
for example and then mock axios
.
<!-- the submit event will no longer reload the page -->
<form v-on:submit.prevent="onSubmit"></form>
It’s an easier way to unit-test that.
Source:stackexchange.com