ember-css-modules-sass icon indicating copy to clipboard operation
ember-css-modules-sass copied to clipboard

Use a sass 'global' variable

Open adambedford opened this issue 5 years ago • 1 comments

I'm trying to get this up and running in conjunction with bootstrap (from ember-bootstrap) and I would like to reference one of bootstrap's variables in my component sass file.

e.g.

.label-wrapper {
  background-color: $light
}

...where $light comes from bootstrap.

This is currently throwing an 'undefined variable' error. Is there a different pattern I should be using? I'm migrating from ember-component-css, so please tell me to RTFM if I'm just missing something 😄

adambedford avatar Jan 14 '20 18:01 adambedford

I have had a similar issue. For me the bootstrap import ended up below the usage of the variable in the resulting app.scss file which caused the 'undefined variable' error.

For me it seemed related to styling reuse via the 'composes' property, which I guess is related to #3

dagroe avatar Jan 21 '20 19:01 dagroe