So, first of all I have the following configuration:
- Rails 4.0.2
- Sass 3.2.13
- Compass 0.12.2
And my files are below:
Gemfile
...
gem 'sass-rails'
gem 'compass-rails'
gem 'breakpoint'
gem 'singularitygs'
...
application.css.scss
/* Mixins */
@import 'compass';
@import 'breakpoint';
@import 'singularitygs';
/* Variables */
$grids: 12;
$gutters: 1/3;
/* Styles */
* { @include box-sizing('border-box'); }
.container {
@include background-grid;
margin: 0 auto;
min-height: 100%;
max-width: 960px;
@include clearfix;
}
header {
.logo { @include grid-span(4, 1); }
.user { @include grid-span(4, 8); }
}
HTML
<header>
<div class="container">
<div class="logo">Logo</div>
<div class="user">User</div>
</div>
</header>
The grid-span function is returning nothing (blank). This image represents what I expect:

And this, what I have:

Does anyone have any idea how can I solve it to work properly?
It appears that the only thing you're missing is the
Output Style, because of which thedivs are going to render default which is one stacked on top of other.Update your
application.css.scss's variables section as follows (Not required to be defined here but this is where it would make more sense!, i.e. with$gridsand$gutters):This will set the output style to
floatand yourgrid-spandivs shouldfloatas you've shown in your expected result.