Sha256: c76e4e3e0783a5ec14e7e97fbf3f4c1259a994f389eb9f110a8a898f5d4b01ed

Contents?: true

Size: 1.78 KB

Versions: 1

Compression:

Stored size: 1.78 KB

Contents

# FrontendGenerators

The FrontendGenerators gem lets you easily copy the Bootstrap & Font Awesome css, js, and fonts directly into your application.  Most people use [twitter-bootstrap-rails](https://github.com/seyhunak/twitter-bootstrap-rails) and [font-awesome-rails](https://github.com/bokmann/font-awesome-rails) to access these frontend libraries in their code, but I find it much easier to just have the code in my own applications.  It's easier to examine the source code when it's in your application and you can avoid frusterating Rails asset pipeline bugs with this straightforward setup.  Annoying bugs are what motivated me to create this gem in the first place.

## Installation

Add this line to your application's Gemfile (the `require: false` part is important):

```ruby
gem 'frontend-generators', require: false
```

And then execute:

    $ bundle

Update your `Rakefile` with this code:

```ruby
require "frontend_generators"
load 'tasks/add_assets.rake'
```

## Moving Bootstrap Code to Your Application

To move the Bootstrap files into your Rails application, run this rake task:

```ruby
bundle exec rake add_assets:bootstrap
```

Go to `application.css` and add this line:

```css
*= require bootstrap
```

Go to `application.js` and add this line:

```javascript
//= require bootstrap
```

## Moving Font-Awesome Code to Your Application

To move the Font-Awesome files into your Rails application, run this rake task:

```ruby
bundle exec rake add_assets:font_awesome
```

Go to `application.css` and add this line:

```css
*= require font_awesome
```

## Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/MrPowers/frontend-generators.


## License

The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
frontend-generators-0.0.1 README.md