'use client'; import { useState, useEffect } from 'react'; import { useTheme } from 'next-themes'; import Link from 'next/link'; import { Shimmer } from '@shimmer-from-structure/react'; import { Header } from './Header'; import { Footer } from './Footer'; import { NpmDownloadStats } from './NpmDownloadStats'; import { LatestRelease } from './LatestRelease'; import { ShimmerProvider } from '@shimmer-from-structure/react'; import type { Release } from '../../lib/changelog'; interface HomeContentProps { latestRelease: Release; } /** macOS-style terminal window for code example */ function QuickExampleTerminal() { return (
import{' '}
{'{ Shimmer }'}{' '}
from{' '}
'shimmer-from-structure'
;
{'\n\n'}
function{' '}
UserCard
() {'{'}
{'\n '}
return{' '}
(
{'\n '}
{'{' '}
loading
={'{'}
isLoading
{'}'}
{'>'}
{'\n '}
{'{' '}
className
=
"card"
{'>'}
{'\n '}
{'
{' '}
src
=
"avatar.jpg"{' '}
className
=
"avatar"{' '}
{'/>'}
{'\n '}
{''}
John Doe
{''}
{'\n '}
{''}
Software Engineer
{''}
{'\n '}
{''}
{'\n '}
{''}
{'\n '}
);
{'\n'}
{'}'}
A structure-aware skeleton loader that mirrors your rendered UI at runtime. Zero layout duplication. Built for modern frameworks.
Automatically measures your component's structure at runtime. No need to maintain separate skeleton components.
Detects border-radius from your CSS automatically. Circular avatars get circular shimmer blocks.
Dedicated adapters for React, Vue, Svelte, Angular, and SolidJS with framework-specific APIs.
Core package is only 1.44 kB. Framework adapters range from 3.89 kB to 12.84 kB.
Use templateProps to provide mock data for components that receive dynamic props.
Default colors use semi-transparent whites that work on any background.
That's it! No skeleton components to maintain.