You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This awesome library, does not seem to be currently capable of generating a style sheet statically and ahead of time (as opposed to, on-demand in response to a known JS environment) to be served to potentially many different browsers on different Platforms for which a union of browser prefix Transforms are needed. For instance, I might want to generate my css with both Firefox and Safari prefixes. Currently, you can subclass DevDefaults to override the default implicit def cssEnv with any singular Platform you wish, e.g.:
object DevDefaults extends Exports with DefaultSettings.Dev {
override implicit val cssEnv: CssEnv = {
// val platform: Platform[Option] = Platform[Option](Some("Chrome"),Some("Blink"),Some("40.0.2214.115"),Some("Chrome 40.0.2214.115 on Linux 64-bit"),None,None,Some("Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.115 Safari/537.36"),Some(OS[Option](Some(Bits64),Some("Linux"),None)))
val platform: Platform[Option] = Platform[Option](Some("Firefox"),Some("Gecko"),Some("36.0"),Some("Firefox 36.0 on Linux 64-bit"),None,None,Some("Mozilla/5.0 (X11; Linux x86_64; rv:36.0) Gecko/20100101 Firefox/36.0"),Some(OS[Option](Some(Bits64),Some("Linux"),None)))
CssEnv(platform, CssEnv.Media.empty(None))
}
}
import DevDefaults._
However, it does not seem to be possible to configure this to generate prefixes for TWO Platforms at the same time. Since Platform and Env are both declared final you cannot subclass and override Env.prefixWhitelist and CanIUse2 is an object that cannot be swapped out.
Is there a current, or could there be a feature added, to permit statically generating style sheets targeting multiple `Platforms simultaneously?
Thank you!
The text was updated successfully, but these errors were encountered:
This awesome library, does not seem to be currently capable of generating a style sheet statically and ahead of time (as opposed to, on-demand in response to a known JS environment) to be served to potentially many different browsers on different
Platform
s for which a union of browser prefixTransform
s are needed. For instance, I might want to generate my css with both Firefox and Safari prefixes. Currently, you can subclassDevDefaults
to override the defaultimplicit def cssEnv
with any singularPlatform
you wish, e.g.:However, it does not seem to be possible to configure this to generate prefixes for TWO
Platform
s at the same time. SincePlatform
andEnv
are both declaredfinal
you cannot subclass and overrideEnv.prefixWhitelist
andCanIUse2
is anobject
that cannot be swapped out.Is there a current, or could there be a feature added, to permit statically generating style sheets targeting multiple `Platforms simultaneously?
Thank you!
The text was updated successfully, but these errors were encountered: