Skip to content

Latest commit

 

History

History
64 lines (41 loc) · 1.65 KB

API.md

File metadata and controls

64 lines (41 loc) · 1.65 KB

Table of Contents

Skeleton

src/components/Skeleton.js:7-31

Extends PureComponent

Skeleton

propTypes

src/components/Skeleton.js:12-15

Properties

  • renderSkeleton func 自定义skeleton
  • children any

SkeletonView

src/components/SkeletonView.js:24-49

Extends PureComponent

SkeletonView : Skeleton容器

Examples

simple usage

<SkeletonView show={true}>
    <Skeleton>
        <span>title</span>
    </Skeleton>
</SkeletonView>

custom skeleton

<SkeletonView show={true}>
    <Skeleton renderSkeleton={()=>(<p style={{backgroundColor:"silver"}}>placeholder</p>)}>
        <span>title</span>
    </Skeleton>
</SkeletonView>

propTypes

src/components/SkeletonView.js:29-32

Properties

  • show bool [false] - 是否显示skeleton
  • children any