Closed titouanmathis closed 5 years ago
This is neat.
$base
to rem
as in current state ? space
is a reserve name ? To handle legacy where we use space('x2')
I guess this is a breaking change.
@perruche in my example, the $base
value is in pixels, but we will keep it in rem
in the default configuration I think.
It seems that space
is not reserved in Sass, and we could handle the legacy code in the @function space
with warnings.
Yeah i was not refering to sass but to our codebase, which already contain the space
function.
I replaced it with the new one 😉
Solved with the merge of the PR #10.
Currently, the
$spaces
map definition depends on the$space-base
definition :We can't override the
$spaces
map in a project's configuration file without redefining the$spaces-base
variable before.It would be nice to have a map only containing values without keys and let the
space($value)
function do the math:See this Codepen for a demo.
I will open a PR with these modifications, but do we consider them breaking changes or not? How could we handle legacy?