-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
$menu->add method #29
Comments
You need to use $menu->add([
'url' => ['dashboard/settings'],
'title' => 'Settings',
'icon' => 'fa fa-cog',
'attributes' => [
'target' => '_blank'
],
'order' => 5
]); I would improve this feature in next release. Thanks! |
If i change it to an
I get an error in:
If i add an empty array to the route array like so:
That fixes the problem. If I add something besides an array it adds the |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
When trying to create a menu item using the
$menu->add
method with the following:option I get an error:
Route [d] not defined.
The Menu seems to be looking for the first character of the named route instead of the entire named route. Works fine if i switch to
'url' => 'path/name'
like so:Is this an error with the menu system, or an error in the documentation? How can i used named routes with the add method? As far as i can tell the only way to add an icon to a menu item is via the
$menu->add
method.The text was updated successfully, but these errors were encountered: