Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation updated #448

Merged
merged 1 commit into from
Nov 14, 2012
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions README.md
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -121,6 +121,29 @@ You have to require Bootstrap LESS (bootstrap_and_overrides.css.less) in your ap
/* Your stylesheets goes here... */ /* Your stylesheets goes here... */
``` ```


To use individual components from bootstrap, your bootstrap_and_overrides.less could look like this:

```css
@import "twitter/bootstrap/reset.less";
@import "twitter/bootstrap/variables.less";
@import "twitter/bootstrap/mixins.less";
@import "twitter/bootstrap/scaffolding.less";
@import "twitter/bootstrap/grid.less";
@import "twitter/bootstrap/layouts.less";
@import "twitter/bootstrap/type.less";
@import "twitter/bootstrap/forms.less";
@import "twitter/bootstrap/wells.less";
@import "twitter/bootstrap/component-animations.less";
@import "twitter/bootstrap/buttons.less";
@import "twitter/bootstrap/close.less";
@import "twitter/bootstrap/navs.less";
@import "twitter/bootstrap/navbar.less";
@import "twitter/bootstrap/labels-badges.less";
@import "twitter/bootstrap/hero-unit.less";
@import "twitter/bootstrap/utilities.less";
@import "twitter/bootstrap/responsive";
```

If you'd like to alter Bootstrap's own variables, or define your LESS If you'd like to alter Bootstrap's own variables, or define your LESS
styles inheriting Bootstrap's mixins, you can do so inside bootstrap_and_overrides.css.less: styles inheriting Bootstrap's mixins, you can do so inside bootstrap_and_overrides.css.less:


Expand All @@ -141,6 +164,20 @@ $(document).ready(function(){
}); });
``` ```


If you want to customize what is loaded, your application.js would look something like this

```js
#= require jquery
#= require jquery_ujs
#= require twitter/bootstrap/bootstrap-transition
#= require twitter/bootstrap/bootstrap-alert
#= require twitter/bootstrap/bootstrap-modal
#= require twitter/bootstrap/bootstrap-button
#= require twitter/bootstrap/bootstrap-collapse
```

...and so on for each bootstrap js component.

## Using Coffeescript (optionally) ## Using Coffeescript (optionally)


Using Twitter Bootstrap with the CoffeeScript is easy. Using Twitter Bootstrap with the CoffeeScript is easy.
Expand Down