How to avoid redirect in Vue 3 composition API using ajax

I’m trying to let the data in a submission form be sent to my email and also added to a google sheet. I found one way of doing it from this link github link. It actually worked for both the purposes I used it for.

My problem is after submitting the form, the page redirects to a json page but I don’t want that to happen. I’ve tried the method they added in the repo but it didn’t work. They mentioned Ajax in the repo but I can’t figure out how to make it work
this is a vue play ground to what I want to do Vue Playground