How do I get the the browser URL in Purescript, just like when doing window.location.href
in javascript?
import Web.HTML (window)
import Web.HTML.Window (location)
import Web.HTML.Location (pathname)
import Effect.Console (log)
main :: Effect Unit
main = do
l <- window >>= location >>= pathname
log $ l