0.1.6 • Published 3 years ago

light-skeleton v0.1.6

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

Light Skeleton

Light react Skeleton loader

🔧 Installation

  npm i light-skeleton

📦 Usage

Sample: https://codesandbox.io/s/skeleton-loader-sample-5lgoc

  const PreLoader = () => {
    let height = '80px';
    return (
      <React.Fragment>
        <TextSkeleton height={height}/>
      </React.Fragment>
    )
  }
  const PreLoader = () => {
    let Hei = '100px';
    let MB = '15px';
    return (
      <React.Fragment>
        <TitleSkeleton 
          style={{ 
            margin: '5px', 
            marginBottom: MB
            }} 
          width={'90%'}
          height={Hei}
        />
        <TitleSkeleton 
          style={{ 
            margin: '5px', 
            marginBottom: MB
          }} 
          width={'90%'} 
          height={Hei}
        />
      </React.Fragment>
    )
  }

👀 Properties

PropertyAttributeDescriptionTypeexample
widthwidthLoader Widthstring"100%"
heightheightLoader Heightstring"1em"
marginBottommarginBottomadd margin bottomstring"12px"
stylestyleadd stylingobject{{color: red, padding: 20px }}

MIT © hc-oss