Closed caribou-code closed 6 years ago
@caribou-code There is no reason that we couldn't expand this to accept other base units as the unit of measure is mostly irrelevant to how the helper works. It is something we could look into for V3.
Added to potential V3 Roadmap #354
When using the modularScale function it only seems to accept an em value for the base parameter. It seems to be good practice to use rem figures for typography to keep everything relative to a root figure.
Consider this (very contrived) example:
I wouldn't do something as simple as the above in reality but you get the picture. The scenario has come up for me before.
I would want all my h1s to have a consistent font size but since 1rem is not accepted as a base figure, it uses 1em instead, resulting in an inconsistent font size for the h1s. Could the base parameter be changed to accept rem? Or is there a reason for this?