Problem: Full-page loading.

Solution#

html
<div class="mx-auto max-w-prose animate-pulse space-y-4 py-16">
  <div class="skeleton-text h-8 w-2/3"></div>
  <div class="skeleton-text h-4"></div>
  <div class="skeleton-text h-4 w-5/6"></div>
</div>

Why this works#

Mirror the real layout dimensions.

Variants#

  • Responsive: add screen prefixes to the core classes
  • Dark: pair each color utility with its dark: twin
  • Animated: add transition + a state variant for motion

cookbook/index|Cookbook index · utilities/index|Utilities reference · patterns/index|Layout patterns