Module: Shoehorn::Helpers::NavigationHelpers
- Defined in:
- lib/shoehorn/helpers/navigation_helpers.rb
Instance Method Summary collapse
-
#bootstrap_navigation(options = {}) {|elements| ... } ⇒ Object
Render a navigation list.
Instance Method Details
#bootstrap_navigation(options = {}) {|elements| ... } ⇒ Object
Render a navigation list
Examples
(:type => "tabs", :stacked => true) do |nav|
nav.link_to "Nav1", "/link1", :active_nav => true
nav.link_to "Nav2", "/link2"
end
Returns HTML String for the navigation list
19 20 21 22 23 24 25 26 27 28 |
# File 'lib/shoehorn/helpers/navigation_helpers.rb', line 19 def ( = {}) elements = Shoehorn::HelperCollection.new(self) yield elements Shoehorn::Components::Navigation.new( elements, ).to_s end |