I have the following function in scss:
@function remCalc($size, $font-size : $font-size) {
$remSize: $size / $font-size;
@return #{$remSize}rem;
}
But when I want to use it like:
.example {
margin: remCalc(8px) - remCalc(16px);
}
I get
.example {
margin: ...rem-....rem;
}
What I would like to get is:
.example {
margin: ...rem -..rem; // Note the space between "rem -"
}
So my question is how can I do this. I have tried to wrap both function calls inside ()
but that didn't work either.
I hope someone could help me with this. Thanks in advance