0.0
Low commit activity in last 3 years
No release in over a year
Generates HTML based tabs using HTML, CSS, and JavaScript.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 1.5, >= 1.5.9
 Project Readme

Introducing the JsMenuBuilder gem

Usage

require 'jsmenubuilder'


tabs = {
  'London' => '<h3>London</h3><p>Good morning</p>', 
  'Paris' => '<p>Bonjour</p>', 
  'Tokyo' => '<p>Konnichiwa</p>'
}

jmb = JsMenuBuilder.new(:tabs, tabs: tabs, active: '2')
puts jmb.html
puts jmb.to_webpage
File.write '/tmp/foo.html', jmb.to_webpage
`firefox /tmp/foo.html &`

The above example generates a web page containing 3 tabs which are clickable and changes the content without reloading the page.

Resource

jsmenubulder menu tabstab html js css template