Usage of repeating-linear-gradient() CSS function

CSSWeb DevelopmentFront End Technology

Use the repeating-linear-gradient() method to repeat linear gradient.

Example

You can try to run the following code to implement the repeating-linear-gradient() function in CSS

Live demo

<!DOCTYPE html>
<html>
   <head>
      <style>
         #demo {
            height: 300px;
            background: repeating-linear-gradient(green 20%, orange 40%, maroon 40%);
         }
      </style>
   </head>
   <body>
      <p>Repeating linear gradient.</p>
      <div id = "demo"></div>
   </body>
</html>
raja
Published on 07-Jun-2018 11:54:52
Advertisements