src/Item.php
public function isActive(): bool
    {
        if ($this->isNested()) {
            return str_contains(url()->current(), $this->url);
        }

        return url($this->url) == url()->current();
    }
public function isActive(): bool
    {
        if ($this->isNested()) {
            return str_contains(url()->current(), $this->url);
        }

        return url($this->url) == url()->current();
    }
public function isActive ( ) : bool { if ( $ this -> isNested ( ) ) { return str_contains ( url ( ) -> current ( ) , $ this -> url ) ; } return url ( $ this -> url ) == url ( ) -> current ( ) ; }
Check if the current item is active.
Check if the current item is active .