Module: Tabnav::Helper
- Defined in:
- lib/tabnav/helper.rb
Instance Method Summary collapse
-
#render_tabnav(options = {}) {|n| ... } ⇒ Object
This is the main method to be used in your views.
Instance Method Details
#render_tabnav(options = {}) {|n| ... } ⇒ Object
This is the main method to be used in your views. It creates and yields a new instance of Navbar.
options is an optional hash of options that are passed to the navbar, and and used to create the ul.
Finally, this renders the navbar, and concats the result into the view.
11 12 13 14 15 16 |
# File 'lib/tabnav/helper.rb', line 11 def render_tabnav( = {}) n = .new(self, params, .merge(:top_level => true)) yield(n) concat( n. ) nil end |