Loading...
Loading...
Use when animation is limited by browser support, platform capabilities, or technical requirements
npx skill4agent add dylantarre/animation-principles technical-constraintsrequestAnimationFrame// Feature detection
const supportsAnimation =
'animate' in Element.prototype &&
CSS.supports('transform', 'translateZ(0)');
if (supportsAnimation) {
element.animate(keyframes, options);
} else {
element.classList.add('final-state');
}
// Progressive enhancement
@supports (animation: name) {
.element {
animation: fadeIn 200ms ease-out;
}
}-webkit-prefers-reduced-motion