src/Widgets/Bootstrap/Nav.php
public function init()
    {
        parent::init();
        if ($this->route === null && $this->app->getRoute()->controller !== null) {
            $this->route = $this->app->getRoute()->getRoutePath(true);
        }
        if ($this->params === null) {
            $this->params = $this->app->reqHelper->getQueryParams();
        }
        Html::addCssClass($this->options, ['widget' => 'nav']);
    }
public function init()
    {
        parent::init();
        if ($this->route === null && $this->app->getRoute()->controller !== null) {
            $this->route = $this->app->getRoute()->getRoutePath(true);
        }
        if ($this->params === null) {
            $this->params = $this->app->reqHelper->getQueryParams();
        }
        Html::addCssClass($this->options, ['widget' => 'nav']);
    }
Initializes the widget.