ProSkeleton API
ProSkeleton provides loading skeleton screens for Pro components, matching the layout of ProTable, ProList, and ProDescriptions.ProSkeletonProps
Type of skeleton to display.
list- Skeleton for ProTable/ProListdescriptions- Skeleton for ProDescriptionsresult- Skeleton for Result page
Whether to show animation.
List Skeleton Props
Whentype="list":
Whether to show page header skeleton.Can be an object to customize:
Whether to show toolbar skeleton.Can be an object to customize:
Whether to show list skeleton.Can be an object to customize:
Whether to show statistic cards.
boolean- Show/hide statisticsnumber- Number of statistic cards to show
Descriptions Skeleton Props
Whentype="descriptions":
Whether to show page header skeleton.
Whether to show descriptions skeleton.
boolean- Show/hide descriptionsnumber- Number of description items to show
Number of columns for descriptions.
Exported Components
ProSkeleton also exports individual skeleton components:PageHeaderSkeleton
Skeleton for page header.Whether to show animation.
ListToolbarSkeleton
Skeleton for list toolbar.Whether to show animation.
Number of action button skeletons.
TableSkeleton
Skeleton for table.Whether to show animation.
Number of table columns.
Number of table rows.
ListSkeleton
Skeleton for list items.Whether to show animation.
Size of list items.
Number of list items.
ListSkeletonItem
Skeleton for a single list item.Whether to show animation.
Size of the list item.
DescriptionsSkeleton
Skeleton for descriptions.Whether to show animation.
Number of description items.
Number of columns.
TableItemSkeleton
Skeleton for a table item row.Whether to show animation.
Number of columns in the row.
Usage Examples
- List Skeleton
- Descriptions Skeleton
- Result Skeleton
- With Loading State
- Individual Components
Best Practices
-
Match component type: Use
type="list"for ProTable/ProList andtype="descriptions"for ProDescriptions to match the actual component layout. - Show during data loading: Display skeleton while fetching data from API to improve perceived performance.
-
Customize for your layout: Adjust
rows,columns, and other props to match your actual component configuration. -
Keep animations: The default
activeanimation provides better visual feedback. -
Hide unnecessary parts: Set
pageHeader={false}ortoolbar={false}if your component doesn’t have those sections.