Skip to content

v3.1.0: Skeletonize

Latest

Choose a tag to compare

@Mostafashadow1 Mostafashadow1 released this 21 Oct 20:22

New: Skeletonize

Wrap any component and it becomes its own skeleton while loading. No second skeleton layout to keep in sync.

import { Skeletonize } from "react-loadly";

<Skeletonize loading={isLoading}>
  <UserCard user={data ?? placeholderUser} />
</Skeletonize>
  • Text, images, icons and form controls become skeleton blocks with the exact size and position of the real UI.
  • Works with hooks, context, Tailwind and any CSS. SSR and Next.js App Router ready.
  • Accessible: content is inert and aria-hidden, with one role="status" message.
  • shimmer, wave, pulse and none animations, reduced-motion support, theme from SkeletonGroupLoader.

Live examples

Fixes

  • require("react-loadly") returned an empty object in CommonJS projects (Jest, older SSR setups). CommonJS bundles now use .cjs and ship .d.cts typings.
  • AutoSkeletonLoader now detects hooks in bundler-compiled components and falls back safely.

Other changes

  • Smaller package: 32 files instead of 972; duplicated type trees are no longer published.
  • AutoSkeletonLoader is deprecated and will be removed in v4. Use Skeletonize or SkeletonLoader.
  • The test suite runs on React 18 and 19 (172 tests).
npm install react-loadly@3.1.0