GolfingStat News and Information

Main menu

Tag Archives: Bootstrap

I have finished scaffolding the site (Release 1) and now have moved on to the UX and final development phase. After some consideration I decided to use the Twitter Bootstrap framework rather than designing from scratch.

Here is an outline of the analysis which went into my decision…

Bootstrap – Pro’s

Save ~40 hours of css pain

Output is better than I could produce (being honest with myself)

Quicker wins (Can start crossing off pages as being complete and I will feel better about the positive momentum)

Scaffolding was built using the blueprint framework (based on my experience completing the Rails Tutorial book examples) and a lot of my divs use the “span-x” classes to specify widths so moving to Bootstrap is pretty easy

Cross-browser compatible out of the box

Bootstrap – Con’s

Looks like every other site released in the last year

Spending time customizing which probably could be used writing CSS from scratch

To do properly requires me to enable the Rails asset pipleine which requires me to read/understand the Rails asset pipeline

In the end the fact that I could save a weeks worth of work and have a better product won out and going with Bootstrap was clearly the best choice for my particular project.

Adding Bootstrap to my Rails app was pretty straight forward. I followed the Twitter Bootstrap Basics Railscast and choose to use the ‘twitter-bootstrap-rails’ gem. If it is good enough for Ryan Bates then it is probably good enough for me. The only issue I had following the directions was that Ryan’s instructions have ‘twitter-bootstrap-rails’ in the assets section of the Gemfile as follows:

Ruby

1

2

3

group:assetsdo

gem'twitter-bootstrap-rails'

end

Which was giving me errors because Rails wasn’t able to find the Twitter code. Instead of having the ‘twitter-bootstrap-rails’ gem in the assets group I moved it into the main section of the Gemfile and my problems went away.