Read more

What Sass means by "@function rules may not contain style rules."

Arne Hartherz
October 31, 2022Software engineer at makandra GmbH

When writing a Sass function, you may run into an error message that may be confusing:

@function rules may not contain style rules.
Illustration web development

Do you need DevOps-experts?

Your development team has a full backlog? No time for infrastructure architecture? Our DevOps team is ready to support you!

  • We build reliable cloud solutions with Infrastructure as code
  • We are experts in security, Linux and databases
  • We support your dev team to perform
Read more Show archive.org snapshot

What Sass is trying to tell you is that a line in your Sass function is computing a result that is neither assigned to a variable nor returned.

Keep in mind that all functions in Sass return something, Sass does not mutate objects.

Posted by Arne Hartherz to makandra dev (2022-10-31 16:10)