1.2.1 • Published 2 years ago

tiny-skeleton-loader-react v1.2.1

Weekly downloads
647
License
MIT
Repository
github
Last release
2 years ago

tiny-skeleton-loader-react

zero dependency, ultra lightweight (1KB gzipped) skeleton loader component for react ✨

Example

GitHub Actions Status NPM gzip

🔧 Installation

npm install --save tiny-skeleton-loader-react

📦 Usage

import React from "react";

import SkeletonLoader from "tiny-skeleton-loader-react";

class Example extends React.Component {
  render() {
    return <SkeletonLoader />;
  }
}

👀 Properties

PropertyAttributeDescriptionTypeDefault
widthwidthLoader Widthstring"100%"
heightheightLoader Heightstring"1em"
backgroundbackgroundLoader background colorstring"#eff1f6"
circlecircleMake Skeleton Circlebooleanfalse
borderRadiusborder-radiusLoader radiusstring"4px"
blockblockWhether to start newbooleantrue
stylestyleExtra Stylesobject{}
as--The HTML elementstring"div"

License

MIT © hc-oss