https://github.com/acrool/acrool-react-skeleton
skeleton component for Reactjs
https://github.com/acrool/acrool-react-skeleton
reactjs skeleton
Last synced: about 1 month ago
JSON representation
skeleton component for Reactjs
- Host: GitHub
- URL: https://github.com/acrool/acrool-react-skeleton
- Owner: acrool
- License: mit
- Created: 2024-09-13T13:12:02.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2024-10-25T00:58:16.000Z (7 months ago)
- Last Synced: 2024-10-25T03:22:14.967Z (7 months ago)
- Topics: reactjs, skeleton
- Language: TypeScript
- Homepage: https://acrool-react-skeleton.pages.dev/
- Size: 1.32 MB
- Stars: 5
- Watchers: 1
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Security: SECURITY.md
Awesome Lists containing this project
- awesome-react - Acrool React Skeleton - Skeleton (React component)
- awesome-react - Acrool React Skeleton - Skeleton (React component)
README
# Acrool React Skeleton
Fast custom skeleton for Reactjs[](https://www.npmjs.com/package/@acrool/react-skeleton)
[](https://github.com/acrool/@acrool/react-skeleton/blob/main/LICENSE)
[](https://github.com/acrool/react-skeleton/blob/main/LICENSE)[](https://www.npmjs.com/package/@acrool/react-skeleton)
[](https://www.npmjs.com/package/@acrool/react-skeleton)## Features
- Support width, height, aspect
- Support round
- Support text mock width## Install
```bash
yarn add @acrool/react-skeleton
```## Usage
add in your index.tsx
```tst
import "@acrool/react-skeleton/dist/index.css";
```then in your page
```tsx
import {Flex, fr, Grid} from '@acrool/react-grid';
import styled from 'styled-components';import {Skeleton} from '@acrool/react-skeleton';
import {generatorArray} from '@acrool/js-utils/array';const LotteryDrawCardSkeleton = () => {
return
{generatorArray(3)
.map((key) => {
return
;
})}
;
};export default LotteryDrawCardSkeleton;
const Title = styled.div`
font-size: 15px;
padding: 10px;
`;const LotteryDrawCardSkeletonRoot = styled.div`
display: flex;
flex-direction: column;
width: 100%;
height: auto;
border-radius: 8px;
background-color: rgba(255, 255, 255, 1);
border: 1px solid rgba(133, 133, 133, .2);
padding: 10px;
font-size: 12px;
`;```
## Options
if need use `null` value, options type
```json
{
"compilerOptions": {
"strictNullChecks": false
}
}
```There is also a example that you can play with it:
[](https://acrool-react-skeleton.pages.dev)
## License
MIT © [imagine10255](https://github.com/imagine10255)