protected function doRender(RequireTagInterface $tag, $assetName)
    {
        $type = $tag->getType();
        $output = '';

        if ($this->canBeRendered($assetName, $type)) {
            $attributes = $this->prepareAttributes($tag, $assetName);
            $this->assetRendered($assetName, $type);

            $output = RequireUtil::renderHtmlTag($attributes, $tag->getHtmlTag(), $tag->shortEndTag());
        }

        return $output;
    }