Laravel Sprintf Span в контроллере

$labels[] = sprintf('<span class="label label-info">%s</span>', $str);
Snippets