Use clip-path in Tailwind CSS
Explanation of how to use clip-path in Tailwind CSS.
2025-6-3
Version
- tailwindcss 4系
I will explain how to use clip-path
in Tailwind CSS 4.
You can specify it by enclosing it in []
.
A space is specified using _
.
<span class="[clip-path:polygon(50%_0,0_100%,100%_100%)]"></span>
This will be output as follows.
clip-path: polygon(50% 0, 0 100%, 100% 100%);