vidzig/frontend/Util.hx

13 lines
276 B
Haxe

import js.Browser;
@:native("paused")
extern var paused: Bool;
/**
Resolves a relative URL like that used in hrefs to a normal, full URL.
*/
function resolveUrl(s:String):String {
var a = Browser.document.createAnchorElement();
a.href = s;
return a.href;
}