Hello!
If you just try:
.container {
--duration: 1.8s;
animation: rotate var(--duration) linear infinite;
}
@keyframes rotate {
from {
transform: rotate(0deg);
}
to {
transform: rotate(-360deg);
}
}
on the Playground it will result to:
.EgL3uq_container {
--duration: 1.8s;
animation: rotate var(--duration) linear infinite
}
@keyframes EgL3uq_rotate {
0% {
transform: rotate(0deg)
}
to {
transform: rotate(-360deg)
}
}
As you can see in the animation CSS property, the name of animation is without hash. If you remove the css variable, the transformation will succeed.