Skip to content

Instantly share code, notes, and snippets.

@yujp
Last active February 11, 2020 07:07
Show Gist options
  • Select an option

  • Save yujp/f69d850e9d042521c0578f7c18613fe5 to your computer and use it in GitHub Desktop.

Select an option

Save yujp/f69d850e9d042521c0578f7c18613fe5 to your computer and use it in GitHub Desktop.
# how to compile: nim c -d:release hello.nim
import asyncdispatch
import httpClient
proc main() {.async.} =
var client = newAsyncHttpClient()
echo await client.getContent("http://google.com")
waitFor main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment