Last active
August 19, 2020 10:31
-
-
Save alvnrapada/ac81b2b3ef23029de257600cd3d25a69 to your computer and use it in GitHub Desktop.
This file contains 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
_initRequest() { | |
const xhr = this.xhr = new XMLHttpRequest(); | |
xhr.open('POST', this.url, true); | |
xhr.responseType = 'json'; | |
xhr.setRequestHeader('Access-Control-Allow-Origin', '*') | |
xhr.setRequestHeader('Authorization', 'YOUR_TOKEN') | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment