I have a file main.sass and screen.sass Screen.sass I connect to main.sass via import
@import 'screen' There is a variable in main.css
$green: #5dca88 I use this variable in screen.sass like this:
border-top: 1px solid $green But for some reason an error is obtained: sass \ screen.sass
Error: Undefined variable: "$green". on line 26 of sass/screen.sass >> border-top: 1px solid $green; I tried to import before the variable was announced and after - nothing helps. Tell me what am I doing wrong? How to make it possible to use variables from the parent file in the internal files?
csstocss, and in the errorsassfile. So what do you end up using? - E_Kscreen.sassto_screen.sassand then in themain.sassfilemain.sassfirstmain.sassvariable, and then make the import. - E_K