Pages
core
Search
Entities
Url
Functions
Creates an url from the given file, which is available until the current window is closed.
File.fromString("Content", "test.html", "text/html")
|> Url.createObjectUrlFromFile()
Creates an url from the given content and type, which is available until the current window is closed.
Url.createObjectUrlFromString("Content", "text/html")
Parses the given string as an Url
.
Url.parse("https://www.example.com").host == "www.example.com"
Releases an existing object URL which was previously created.
Url.createObjectUrlFromString("Content", "text/html")
|> Url.revokeObjectUrl()
Converts the given Url
to a String
.
(Url.parse("https://www.example.com/path/?search=foo#hash")
|> Url.toString()) == "https://www.example.com/path/?search=foo#hash"