Open this example in the interactive library
Source code
<button
class="demo transition-transform duration-400 ease-[cubic-bezier(.2,.8,.2,1)] hover:translate-x-2"
type="button"
>
Try this button
</button>
Ease a transition with a custom curve with Tailwind CSS 4 utilities. The preview uses precompiled styles.
Open this example in the interactive library
<button
class="demo transition-transform duration-400 ease-[cubic-bezier(.2,.8,.2,1)] hover:translate-x-2"
type="button"
>
Try this button
</button>