DEV Community

Chloe
Chloe

Posted on

TIL CSS conic gradient

I'm currently working my way through a udemy course building out some small projects with CSS and vanilla javascript and I learnt about conic gradients.

CSS gradients despite learning about them a long time ago are something I rarely use and have to look up every time, but I'd never heard of conic gradients until it appeared in this project.

Info on MDN

Example:

.gradient {
  background: conic-gradient(red, orange, yellow, green, blue);
}
Enter fullscreen mode Exit fullscreen mode

They create a cool effect and definitely something I will try and find a use for in future projects. Does anyone have use case for this type of gradient?

Top comments (0)