Open MoOx opened 10 years ago
For those cases I don't think there is a benefit to acting as a fallback? Since the values don't change at runtime in those cases, so it would just be duplicate code?
It's a bit like having prefixed & non prefixed version. And for example Firefox 31+ already support custom property (so variables too), this will be nice to be able to debug in the inspector using variable name & not "rendered" version. See https://github.com/reworkcss/rework-vars/issues/28
Here is why I would like to be able to use myth as a fallback (at least during debug ?)
rework-vars & rework-calc have PRs (reworkcss/rework-vars#29 & reworkcss/rework-calc#3) & that hopefully will be merged should soon. @ianstormtaylor are you interested to get a PR for the color part ? I'll be very happy to bring that possibility for this part of myth too.
Interesting, yeah I think I'd be down for a pull request. It might be something we want to put behind a flags like fallbacks: true
? and keep it off by default since it will increase the output?
Sure. What about preserve
(default to false
for now)
Edit: let's go for it
What about adding the possibility to keep original sources & just add rules as fallback before the other ? If I take you example on the homepage:
should yield into
but instead give (note that the homepage include
:root
in the output while it's not here)