~~~php
$class = ArrayHelper::getValue($item, 'class', 'yii\bootstrap\Nav');
return $class::widget($config);
~~~