tamia-ajax-form
v0.1.0
Published
Forms ajaxification for Tâmia
Downloads
2
Readme
Tâmia Ajax Form
Forms ajaxification for Tâmia.
Installation
$ npm install --save-dev tamia-ajax-form
Usage
ajaxForm({
form: formElem,
url: 'http://example.list-manage.com/subscribe/post',
type: 'jsonp',
jsonpCallback: 'c',
onSuccess: data => {
console.log('Yep :-)');
return {
result: 'success',
};
},
onError: data => {
console.log('Nope :-(');
return {
message: data.message,
};
},
});
License
The MIT License, see the included License.md file.