Created
October 31, 2018 16:04
-
-
Save TehShrike/c8afda9c15b7061e4a57b7d9d7f9777e to your computer and use it in GitHub Desktop.
deno issue
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
const main = async () => { | |
const getResponse = await fetch('https://postman-echo.com/get', { | |
headers: { | |
'User-Agent': 'test' | |
} | |
}) | |
console.log('GET response:', await getResponse.text()) | |
const postResponse = await fetch('https://postman-echo.com/post', { | |
headers: { | |
'User-Agent': 'test' | |
} | |
}) | |
console.log('POST response:', await postResponse.text()) | |
} | |
main().catch(err => { | |
console.error(err) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment