Last active
August 22, 2018 13:46
-
-
Save steevehook/1ba8356f900c11921feaa99b93748a1f to your computer and use it in GitHub Desktop.
Pure value css variable
This file contains 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
.block { | |
--d: 30; | |
width: calc(var(--d) * 1vw); | |
height: calc(var(--d) * 1vh); | |
} | |
/* | |
Number --> Unit: calc(var(--v) * 1px) | |
Unit --> Number: You can't | |
*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment