Create a Gradual CSS Linear Gradient what value i need to use in the linear gradient

Tell us what’s happening:

Your code so far


<style>

  div{ 
    border-radius: 20px;
    width: 70%;
    height: 400px;
    margin: 50px auto;
   
  }

</style>

<div></div>

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.181 Safari/537.36.

Link to the challenge:
https://learn.freecodecamp.org/responsive-web-design/applied-visual-design/create-a-gradual-css-linear-gradient

Hello. You can use the Attribute background:linear-gradient(indicator, color1, color2) ; by indicator I mean the direction of the gradient. For example if the indicator is left the gradient will start from left to right. Likewise if the indicator is right, it will begin from right to left etc. Color1 and color2 can by anything you like, for example plain colors like red, blue, yellow or hexademical values or rbg values. There is no limit as to how many colors you can use, I just used 2 colors for the example. There is also a final attribute which you need to include before the linear gradient according to the browser you need to display it to. For example background:-moz-linear-gradient etc will make it available for Firefox while background:-webkit-linear-gradient will make it available for Chrome.

1 Like