What character can be used in a SCSS/SASS function and variable name?

sawa

What characters can be used in SCSS/SASS function names and variable names? I want to know especially which non-alphabets like _, -, numbers, punctuations, etc. can be used.

Joe

http://sass-lang.com/documentation/file.SASS_CHANGELOG.html#variable_and_mixin_names

The current version of SASS is 3.4.5 (Sep 19, 2014). As of version 3.0.0, the following is true:

SassScript variable and mixin names may now contain hyphens. In fact, they may be any valid CSS3 identifier. For example:

$prettiest-color: #542FA9
=pretty-text
  color: $prettiest-color

There's no mention of any restrictions on function names in the official documentation, and from the source it appears to not do any kind of error-checking whatsoever. A "valid function name" appears to be completely undocumented.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

How can I find out the name of a variable inside a function?

From Dev

What else can `loeb` function be used for?

From Dev

Character escaping in variable name

From Dev

what range of values can a character variable hold in C?

From Dev

MatLab: Variable assigned during function can be used in another function

From Dev

How does it make sense to use the variable name used to name a function inside that same function?

From Dev

What are the different character sets used for?

From Dev

How can use variable class name and function in Python

From Dev

Can I use the value of a variable as a parameter name for a function?

From Dev

Can you call a function using the value of a variable as the function name?

From Dev

Julia - can a global variable be used in a function before it is defined?

From Dev

What can `inxi` be used for?

From Dev

Period character used for local computer name

From Dev

What is a name of this port? And for what purpose can it be used?

From Dev

What memory used for variable declared outside of a method or function

From Dev

How can I find out the name of a variable inside a function?

From Dev

What is the "Character Map" application used for?

From Dev

Character escaping in variable name

From Dev

what range of values can a character variable hold in C?

From Dev

Scala: How can I get the name of a variable class in a function?

From Dev

What's the name and where can I find this strange RTL character?

From Dev

What can `inxi` be used for?

From Dev

python: how can I pass a variable to a function with only the string name

From Dev

Instance Variable can be used by method and also local variable can be declared inside the method with the same name as of instance variable in Java

From Dev

MySQLi query in variable/function (that can be later used to echo content)

From Dev

Can a function be used in a equation

From Dev

What does it mean that "DWORD can be used to declare a variable that contains the 32-bit offset of another variable"?

From Dev

Python escape '$' character in variable name

From Dev

Can not update global variable used in function(Python)

Related Related

  1. 1

    How can I find out the name of a variable inside a function?

  2. 2

    What else can `loeb` function be used for?

  3. 3

    Character escaping in variable name

  4. 4

    what range of values can a character variable hold in C?

  5. 5

    MatLab: Variable assigned during function can be used in another function

  6. 6

    How does it make sense to use the variable name used to name a function inside that same function?

  7. 7

    What are the different character sets used for?

  8. 8

    How can use variable class name and function in Python

  9. 9

    Can I use the value of a variable as a parameter name for a function?

  10. 10

    Can you call a function using the value of a variable as the function name?

  11. 11

    Julia - can a global variable be used in a function before it is defined?

  12. 12

    What can `inxi` be used for?

  13. 13

    Period character used for local computer name

  14. 14

    What is a name of this port? And for what purpose can it be used?

  15. 15

    What memory used for variable declared outside of a method or function

  16. 16

    How can I find out the name of a variable inside a function?

  17. 17

    What is the "Character Map" application used for?

  18. 18

    Character escaping in variable name

  19. 19

    what range of values can a character variable hold in C?

  20. 20

    Scala: How can I get the name of a variable class in a function?

  21. 21

    What's the name and where can I find this strange RTL character?

  22. 22

    What can `inxi` be used for?

  23. 23

    python: how can I pass a variable to a function with only the string name

  24. 24

    Instance Variable can be used by method and also local variable can be declared inside the method with the same name as of instance variable in Java

  25. 25

    MySQLi query in variable/function (that can be later used to echo content)

  26. 26

    Can a function be used in a equation

  27. 27

    What does it mean that "DWORD can be used to declare a variable that contains the 32-bit offset of another variable"?

  28. 28

    Python escape '$' character in variable name

  29. 29

    Can not update global variable used in function(Python)

HotTag

Archive