3

I am trying to import the variables file into a sub-project. I want to have a single variables file, which would give theme to the both main and sub-project.

Hence, I am importing the variables file by using the full path in my sub-project, like :

@import "http://main-project-url/scss/_variables.scss"; 
OR 
@import url("http://main-project-url/scss/_variables.scss ");

However, I am getting errors while accessing those variables declared in _variables.scss file. Can someone help me, please..!

Thanks in advance! SuryaPavan

SuryaPavan
  • 347
  • 1
  • 6
  • 18
  • were you ever able to get this figured out? I am trying to accomplish the same thing. I have CodeKit and Intellij for compiling but it does not seem to work! – PropSoft Jun 03 '14 at 16:22

1 Answers1

2

Because @import is overloaded in SASS, it's hard to tell but just because it compiles does not mean that the variables in .scss are getting interpreted.

You might look at remote-sass which purports to do what you ask:

RemoteSass is a small gem that allows Sass to import remote sass/scss stylsheets over HTTP/S. With this, you can set up a central server to serve your stylesheet assets and share css among your many applications.

artlung
  • 33,305
  • 16
  • 69
  • 121