Autarky\Routing\UrlGenerator::getRootUrl PHP Method

getRootUrl() public method

Get the root URL. Used to generate URLs to assets.
public getRootUrl ( ) : string
return string
    public function getRootUrl()
    {
        $request = $this->requests->getCurrentRequest();
        $host = $request->getHttpHost();
        $base = $request->getBaseUrl();
        return rtrim("//{$host}/{$base}", '/');
    }