Search code examples
rubygemszurb-foundationcompass-geolocationcodekit

How to select with version of Zurb Foundation to use for a CodeKit + Compass + Sass Project


I was hoping to use the new version (v4) of Foundation for a responsive project I'm working on so I installed v4 via gem install zurb-foundation the other day and got CodeKit up and running with it. However, my client has asked that we support IE8 (God help me) because we still have a significant amount of traffic showing up in analytics.

Version 4 of Foundation doesn't support IE8 because its Mobile-First. V3 works differently and can still support IE8.

So i'm trying to figure out how to back track. I installed the latest V3 Foundation GEM via gem install zurb-foundation -v 3.2.5 but I am not sure how to force CodeKit + Compass to use V3 instead of V4.

Also, when I set up my new project with V4 I had created a COMPASS project in CodeKit and then via the terminal followed this commands to build the Foundation framework in the new Compass project folder:

1. Add require "zurb-foundation" to your config.rb file
2. cd path/to/your-project
3. run compass install foundation

So now that I have GEMS for v3 and v4 in my system, how can I just work with 3 for this project and set up the folder similarly.

Any help is GREATLY appreciated. I'm fairly new to using CodeKit + Compass + SASS, so be gentle and feel free to be as verbose as you like :)


Solution

  • Config.rb in a foundation project is a simple ruby environment file, so selecting the version of zurb-foundation is the same as requiring a specific version of any other gem.

    gem 'zurb-foundation', '=3.2'
    require 'zurb-foundation'