Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sass @use rule doesn't compile with additional Scss files #22

Open
WesMC opened this issue Jun 23, 2020 · 3 comments
Open

Sass @use rule doesn't compile with additional Scss files #22

WesMC opened this issue Jun 23, 2020 · 3 comments

Comments

@WesMC
Copy link

WesMC commented Jun 23, 2020

Hello Compile-Hero

When using the SASS / SCSS compile feature, it doesn't compile the added files when using the @use rule.

theme.scss

/*************************** Import Bootstrap  *****************************/
@use '../lib/bootstrap/scss/bootstrap.scss';

/*************************** Theme Styles Section ****************************/
@use 'theme/styles.scss';

/*************************** Theme Colours****************************/
// Define theme colour scheme
$theme-color-primary: #f65f34;
$theme-color-secondary: #E06167;

$theme-text-color-primary: #252930;
$theme-text-color-secondary: lighten($theme-text-color-primary, 25%);
$theme-text-color-light: lighten($theme-text-color-primary, 50%);
...

Compiles To

theme.css

/*************************** Import Bootstrap  *****************************/
@use '../lib/bootstrap/scss/bootstrap.scss';
/*************************** Theme Styles Section ****************************/
@use 'theme/styles.scss';
/*************************** Theme Colours****************************/
/*************************** Variables Section. *****************************/

@WesMC
Copy link
Author

WesMC commented Jun 23, 2020

A Quick Update:

Sass is not compiling variables globally when using @use instead of @import. This causes the need to add the @use variables declaration on EACH .scss file using variables, mixins, functions, etc...

Please see the issue that I created: sass/sass#2876

That being said, the compiler for Compile-Hero still does not recognize @use statements

@Wscats
Copy link
Owner

Wscats commented Jun 24, 2020

@WesMC Thanks for your feedback, I will always pay attention to the progress of sass in this regard.

@zivan2
Copy link

zivan2 commented Jul 1, 2020

@Wscats Have you made any changes? I also can't compile anything with @use.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants