97af50c700
For instance, Firefox iOS is reported as `firefox? true, version 20`. As on iOS only the system-provided Webkit is allowed, we can instead safely assume that all browsers on a recent iOS device are modern.
8 lines
528 B
Ruby
8 lines
528 B
Ruby
# See .browserslistrc
|
|
Browser.modern_rules.clear
|
|
Browser.modern_rules << -> b { b.chrome? && b.version.to_i >= 50 && !b.platform.ios? }
|
|
Browser.modern_rules << -> b { b.edge? && b.version.to_i >= 14 && !b.compatibility_view? }
|
|
Browser.modern_rules << -> b { b.firefox? && b.version.to_i >= 50 && !b.platform.ios? }
|
|
Browser.modern_rules << -> b { b.opera? && b.version.to_i >= 40 }
|
|
Browser.modern_rules << -> b { b.safari? && b.version.to_i >= 8 }
|
|
Browser.modern_rules << -> b { b.platform.ios? && b.platform.version.to_i >= 8 }
|