Created
October 16, 2014 14:44
-
-
Save KittyGiraudel/69daef4a1d5426c80812 to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ---- | |
| // Sass (v3.4.5) | |
| // Compass (v1.0.1) | |
| // ---- | |
| /// Constants map | |
| /// @type Map | |
| /// @prop {Number} MAX_Z_INDEX - 2147483647 | |
| /// @prop {Number} PI - 3.1415926535897932384626433832795028841971693993751 | |
| /// @prop {Number} E - 2.71828182845904523536028747135266249775724709369995 | |
| $CONSTANTS: ( | |
| 'MAX_Z_INDEX': 2147483647, | |
| 'PI': 3.1415926535897932384626433832795028841971693993751, | |
| 'E': 2.71828182845904523536028747135266249775724709369995 | |
| ); | |
| /// Constant getter | |
| /// @param {String} $name - Name of constant to get | |
| /// @return {*} Constant value | |
| /// @require $CONSTANTS | |
| /// @throw 'Unknown constant `#{$name}`.' | |
| @function const($name) { | |
| @if not map-has-key($CONSTANTS, $name) { | |
| @error 'Unknown constant `#{$name}`.'; | |
| } | |
| @return map-get($CONSTANTS, $name); | |
| } | |
| test { | |
| z-index: const('MAX_Z_INDEX'); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| test { | |
| z-index: 2147483647; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment