I'm writing a font declaration with short-hand syntax, and I'm using SASS. I'd like to escape the '/' character to avoid SASS makes the divition operation.
$fontSize: 14px;
$lineHeight: 16px;
$fontName: Arial;
body
{
font: $fontSize/$lineHeight $fontName;
}
This gets compiled to:
font: 0.875 Arial;
What I want to get is something like:
font: 14px/16px Arial;
Any ideas?
font: #{$fontSize}/#{$lineHeight} $fontName
should do it.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With