Can be shortened:
$className = 'Magento\Framework\View\Render\\' . ucfirst($type);
The proof: Online PHP editor | output for 1vV5H
Can be shortened:
$className = 'Magento\Framework\View\Render\\' . ucfirst($type);
The proof: Online PHP editor | output for 1vV5H