Class: ActiveAdmin::Menu
- Inherits:
-
Object
- Object
- ActiveAdmin::Menu
- Includes:
- MenuNode
- Defined in:
- lib/active_admin/menu.rb
Overview
Each Namespace builds up it’s own menu as the global navigation
To build a new menu:
= Menu.new do |m|
m.add label: 'Dashboard', url: '/'
m.add label: 'Users', url: '/users'
end
If you’re interested in configuring a menu item, take a look at the options available in ‘ActiveAdmin::MenuItem`
Defined Under Namespace
Modules: MenuNode
Instance Attribute Summary
Attributes included from MenuNode
Instance Method Summary collapse
-
#initialize {|_self| ... } ⇒ Menu
constructor
A new instance of Menu.
Methods included from MenuNode
#[], #[]=, #add, #current?, #include?, #items
Constructor Details
#initialize {|_self| ... } ⇒ Menu
Returns a new instance of Menu.
18 19 20 21 |
# File 'lib/active_admin/menu.rb', line 18 def initialize super # MenuNode yield(self) if block_given? end |