Skip to content

Instantly share code, notes, and snippets.

@kesarawimal

kesarawimal/axios.js

Last active Feb 15, 2021
Embed
What would you like to do?
FormSubmit AJAX Documentation: Axios
// https://github.com/axios/axios
axios.defaults.headers.post['Content-Type'] = 'application/json';
axios.post('https://formsubmit.co/ajax/your@email.com', {
name: "FormSubmit",
message: "I'm from Devro LABS"
})
.then(response => console.log(response))
.catch(error => console.log(error));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment