Created
July 15, 2016 21:37
-
-
Save alfredoem/9aa5c8098747ff0ac1f48fd4e247f976 to your computer and use it in GitHub Desktop.
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
<script> | |
(function(){ | |
fetch('/endpoint', {method: 'get'}).then(function (response) { | |
return response.json(); | |
}) | |
.then(function (body) { | |
console.log(body); | |
}); | |
})(); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment