Compass / compass-rails

compass rails integration
MIT License
591 stars 276 forks source link

Rails 4.1.1 w/ Compass-rails -- undefined mixins() #252

Closed rhythmspice closed 8 years ago

rhythmspice commented 9 years ago

Hi,

I am on Rails 4.1.1 w/ sass-rails 4.0.3, and compass-rails (no version specified in gem file).

I am trying to use (2) mixins : border-radius and display-flex

in my dashboard.css.scss file, I do:

@import 'compass/css3/flexbox';

That is the only import statement for compass (as I understand it, that should bring in all the main mixins).

@include border-radius(5px) works fine. @include display-flex; does not work.


If I have this code:

@import 'compass';  /*This is all i need to get all the compass core mixins and functionality i think*/
//My css code here

Then I get this error:

Sass::SyntaxError in Dashboard#show
Showing /.../dashboard.html.erb where line #34 raised:

Undefined mixin 'display-flex'.

...


If I have this code:

@import 'compass';
@import 'compass/css3/flexbox'; /*Hm, maybe I need to import this mixin?*/
//My css code here

Then: I get this error:

Sass::SyntaxError in Dashboard#show
Showing /.../dashboard.html.erb where line #34 raised:
Load paths:
  CompassRails::SpriteImporter
  CompassRails::SpriteImporter
  CompassRails::SpriteImporter
  CompassRails::SpriteImporter
  CompassRails::SpriteImporter
  CompassRails::SpriteImporter
  CompassRails::SpriteImporter
  CompassRails::SpriteImporter
  CompassRails::SpriteImporter
  CompassRails::SpriteImporter
  CompassRails::SpriteImporter
  CompassRails::SpriteImporter
  /Users/Brian/Documents/web/FMC/ars/app/assets/fonts
  /Users/Brian/Documents/web/FMC/ars/app/assets/images
  /Users/Brian/Documents/web/FMC/ars/app/assets/javascripts
  /Users/Brian/Documents/web/FMC/ars/app/assets/stylesheets
  /Users/Brian/Documents/web/FMC/ars/vendor/assets/javascripts
  /Users/Brian/Documents/web/FMC/ars/vendor/assets/stylesheets
  /Users/Brian/.rvm/gems/ruby-2.1.0/gems/highcharts-rails-4.0.4.1/app/assets/images
  /Users/Brian/.rvm/gems/ruby-2.1.0/gems/highcharts-rails-4.0.4.1/app/assets/javascripts
  /Users/Brian/.rvm/gems/ruby-2.1.0/gems/turbolinks-2.5.3/lib/assets/javascripts
  /Users/Brian/.rvm/gems/ruby-2.1.0/gems/jquery-rails-3.1.4/vendor/assets/javascripts
  /Users/Brian/.rvm/gems/ruby-2.1.0/gems/coffee-rails-4.0.1/lib/assets/javascripts
  /Users/Brian/Documents/web/FMC/ars/app/assets/fonts
  /Users/Brian/Documents/web/FMC/ars/app/assets/stylesheets
  /Users/Brian/.rvm/gems/ruby-2.1.0/gems/compass-0.12.7/frameworks/blueprint/stylesheets
  /Users/Brian/.rvm/gems/ruby-2.1.0/gems/compass-0.12.7/frameworks/compass/stylesheets
  Compass::SpriteImporter
  (in /Users/Brian/Documents/web/FMC/ars/app/assets/stylesheets/dashboard.css.scss:2)

File to import not found or unreadable: compass/css3/flexbox.
Load paths:

...

Help much appreciated - spent all day on this; no luck with anything.

jsiragusa commented 8 years ago

Experiencing the same issue.
Rails 4.1.1 compass-rails 1.1.7

PierrickGT commented 8 years ago

Have you guys found a solution ? I've got the same problem...

rhythmspice commented 8 years ago

No, had to move on!

On Jan 12, 2016, at 11:37 AM, Pierrick TURELIER notifications@github.com wrote:

Have you guys found a solution ? I've got the same problem...

— Reply to this email directly or view it on GitHub https://github.com/Compass/compass-rails/issues/252#issuecomment-170968154.

PierrickGT commented 8 years ago

In my case, the problem was because I was importing the mixin before Compass. But yours seems a bit more complicated than that.

jsiragusa commented 8 years ago

I also had to drop it and move on, but i will try again double-check that my imports are in the correct order.

jsiragusa commented 8 years ago

Still doesn't seem to be working for me. :/

hamityay commented 6 years ago

Why this issue closed?