Created
September 25, 2017 11:25
-
-
Save johnpili/5cb7a46194b2df3c12c817b55639edba to your computer and use it in GitHub Desktop.
Vue form submit template with headers
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var config = {}; | |
config.headers = {}; | |
config.headers[document.querySelector('meta[name="_csrf_header"]').content] = document.querySelector('meta[name="_csrf"]').content; | |
this.form.submit("post", "https://url.test.com", config); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment