Skip to content

Instantly share code, notes, and snippets.

@MarkTiedemann
Created November 22, 2017 19:03
Show Gist options
  • Save MarkTiedemann/78fc4be34e2524b6d1fc601a1c9c8dec to your computer and use it in GitHub Desktop.
Save MarkTiedemann/78fc4be34e2524b6d1fc601a1c9c8dec to your computer and use it in GitHub Desktop.
document.body.animate(
[
'translateX(-6px)',
'translateX(12px)',
'translateX(-9px)',
'translateX(15px)',
'translateX(-6px)',
]
.map(transform => ({ transform })),
{
duration: 350,
easing: 'cubic-bezier(0.15, 0.70, 0.70, -0.15)'
}
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment