Giter VIP home page Giter VIP logo

compass-rails's Introduction

compass-rails

We Take Pull Requests!

Build Status Code Climate Gem Version Coverage Status

Compass rails is an adapter for the Compass Stylesheet Authoring Framework for Ruby on Rails.

Since Compass v0.12.0, this is the only way to use compass with your rails application.

Supports Rails 3.2, 4.x releases.

Installation

Add the compass-rails gem line to your application's Gemfile

gem 'sass-rails'
gem 'compass-rails'

If you are using any Compass extensions, add them to this group in your Gemfile.

And then execute:

$ bundle

Usage

Change your application.css to application.css.scss or application.css.sass and then @import compass and your own stylesheets to your hearts content. E.g.:

@import "compass";

@import "your_project/mixins";
@import "your_project/base";

or

Use application.css to require files that use compass features. Ex:

/*
 *= require styleguide_full_of_compass_stuff
 */

Don't use *= require something within your SCSS or SASS files. You're gonna have a bad time.

Configuration

Compass-rails is configured out of the box to work with Rails.

Advanced users can choose to add a config/compass.rb and take advantage of the Compass configuration reference as is.

Installing Compass extensions

Step 1: Add it to your Gemfile and run the bundle command to install it.

Step 2: Install the extension's assets: bundle exec compass install <extension/template>

For example, if you want to use susy.

# Gemfile
gem 'compass-rails'
gem 'susy'

then run:

$ bundle
$ bundle exec compass install susy

if you are using the rails configuration files you should add:

config.compass.require "susy"

to your application.rb configuration file.

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Added some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

compass-rails's People

Contributors

scottdavis avatar craigmcnamara avatar chriseppstein avatar rmm5t avatar josepjaume avatar danielpclark avatar nadavshatz avatar parndt avatar slbug avatar tamird avatar skorfmann avatar josh avatar jbarreneche avatar juanger avatar molily avatar michaelabon avatar olivierlacan avatar salimane avatar marocchino avatar twalpole avatar seuros avatar renchaorevee avatar hazg avatar s12chung avatar y-yagi avatar jc00ke avatar jhubert avatar jammons avatar chikamichi avatar jhummel avatar

Watchers

 avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.