Using @supports to check if a CSS property is supported - HTML CSS CSS

HTML CSS examples for CSS:Introduction

Description

Using @supports to check if a CSS property is supported

Demo Code

ResultView the demo in separate window

<html lang="en">
 <head> 
  <style>
p::after {<!--from  w w  w  . j  a  va 2s . c o  m-->
   content:" nope."
}

@supports (display: -moz-grid) {
   p::after {
   content:" yep!"
}
</style> 
 </head> 
 <body translate="no"> 
  <p>Is it Mozilla? </p>  
 </body>
</html>

Related Tutorials