react-content-loader it is a SVG component to create placeholder loading, like Facebook cards loading or also known as skeleton UI. So using this online tool you will be able to create your own loader easily. You just need to draw using the canvas and get the snippet ready for:
- ReactJS;
- React Native;
- VueJS;
- Angular;
- SVG/HTML;
- Maybe Gif someday;
Still not clear? Read the documentation of react-content-loader
Add your loading code in the gallery following the steps bellow and help the community grows.
- Build your custom amazing loading component;
- Create a file with a custom name, here;
- Use the following boilerplate (don't forget to fill the metadata);
- Insert the file in the gallery, here;
- Open a pull request, don't you know how to do it? Read this;
import React from "react";
import ContentLoader from "react-content-loader";
const MyLoader = (props) => (
<ContentLoader
rtl
speed={1}
width={400}
height={150}
viewBox="0 0 400 150"
backgroundColor="#c0c0c0"
foregroundColor="#0080ff"
{...props}
>
<circle cx="10" cy="20" r="8" />
<rect x="25" y="15" rx="5" ry="5" width="220" height="10" />
<circle cx="10" cy="50" r="8" />
<rect x="25" y="45" rx="5" ry="5" width="220" height="10" />
<circle cx="10" cy="80" r="8" />
<rect x="25" y="75" rx="5" ry="5" width="220" height="10" />
<circle cx="10" cy="110" r="8" />
<rect x="25" y="105" rx="5" ry="5" width="220" height="10" />
</ContentLoader>
);
Unique.metadata = {
name: "Kartik Dhiman", // My name
github: "KDhiman123", // Github username
description: " Unique Loader Style", // Loader description
filename: "Unique", // filename of your loader
};
export default Unique;This project was bootstrapped with Create React App, so in the project directory, you can run:
Runs the app in the development mode.
Open http://localhost:5173 to view it in the browser.
The page will reload if you make edits.
You will also see any lint errors in the console.
Thanks goes to these wonderful people (emoji key):
This project follows the all-contributors specification. Contributions of any kind welcome!