Created
October 8, 2011 18:35
-
-
Save brianstorti/1272680 to your computer and use it in GitHub Desktop.
Twitter bootstrap with rails 3.1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Gemfile | |
gem 'twitter-bootstrap-rails' | |
gem 'less' | |
gem 'less-rails', :git => 'git://github.com/metaskills/less-rails.git' | |
applications.css | |
/* | |
*= require bootstrap | |
*/ | |
/* Your stylesheets goes here... */ | |
application.js | |
//= require bootstrap | |
$(document).ready(function(){ | |
/* Your javascripts goes here... */ | |
}); | |
Using with coffeescript | |
create application.js.coffee | |
$ -> | |
$("body > .topbar").scrollSpy() | |
$ -> | |
$(".tabs").tabs() | |
$ -> | |
$("a[rel=twipsy]").twipsy live: true | |
$ -> | |
$("a[rel=popover]").popover offset: 10 | |
$ -> | |
$(".topbar-wrapper").dropdown() | |
$ -> | |
$(".alert-message").alert() | |
$ -> | |
domModal = $(".modal").modal( | |
backdrop: true | |
closeOnEscape: true | |
) | |
$(".open-modal").click -> | |
domModal.toggle() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment