Last active
November 4, 2015 14:37
-
-
Save sdgluck/3fa3d86b3ec6cc2eb875 to your computer and use it in GitHub Desktop.
LESS rem font-size mixin with px fallback. Requires that html, body has font-size: 62.5% such that 1rem = 10px.
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
.font-size (@size) { | |
@px: @size * 10; | |
font-size: e("@{px}px"); | |
font-size: e("@{size}rem"); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment