Is there a way to set animation-delay
equal to i * 1s
where i
stands for index of the element in a parent element? I mean, in pure CSS (with neither Javascript nor LESS/SASS), maybe with calc()
.
Asked
Active
Viewed 359 times
0

Shtole
- 77
- 6
-
2no it's not possible – Temani Afif Jul 02 '22 at 07:50
-
2[This](https://stackoverflow.com/a/51601269/9256189) is the closest you can go. – TechySharnav Jul 02 '22 at 08:08
-
1You can do it in pure CSS but it’s a bit tedious. Just have as many settings of the form: .container > :nth-child(1) { —n: 1; } .container > :nth-child(2) {—n: 2; } etc as you need. How do we lobby to get the n in nth-child(n) usable? – A Haworth Jul 02 '22 at 09:15