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 !global variable declaration deprecation warning #12080

Closed
sprda opened this issue May 19, 2020 · 1 comment · Fixed by #12195
Closed

Sass !global variable declaration deprecation warning #12080

sprda opened this issue May 19, 2020 · 1 comment · Fixed by #12195

Comments

@sprda
Copy link

sprda commented May 19, 2020

foundation-sites 6.6.3

After a LibSass 3.6.4 update I started receiving deprecation warnings, an example follows:

DEPRECATION WARNING on line 120 of foundation-sites/scss/util/_color.scss:
!global assignments won’t be able to declare new variables in future versions.
Consider adding $secondary-color: null at the top level.

snippet reference https://sass-lang.com/documentation/variables
⚠️ Heads up!

Compatibility: Dart Sass since 2.0.0 LibSass✗Ruby Sass✗

Older Sass versions allowed !global to be used for a variable that doesn’t exist yet. This behavior was deprecated to make sure each stylesheet declares the same variables no matter how it’s executed.

The !global flag may only be used to set a variable that has already been declared at the top level of a file. It may not be used to declare a new variable.

@ycrepeau
Copy link
Contributor

ycrepeau commented Jan 23, 2021

Downgrading sassc from 2.40 to 2.2.1 is NOT a solution since it creates incompatibilities with the current version of nodejs (12.x), version installed by default when building a project in docker using the ruby-2.7.2-alpine image.

Waiting for Foundation 7 is not the solution either, the last update on the Project's board dates from November 26th 2019, that's 14 months without any activity. It seems that the Sun will run out of its hydrogen before the Foundation 7 release.

I have managed to fix the problem locally. So, this is what I'll do: I will fork the project, add the patches, commit and submit a pull-request. As we say in French: "On est jamais mieux servis que par soi-même".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Foundation V7
Awaiting triage
3 participants