Simulate Youtube Top Loading Indicator With TopLoader.js

Category: Javascript , Loading | October 31, 2019
Author: loukaspd
Views Total: 105
Official Page: Go to website
Last Update: October 31, 2019
License: MIT

Preview:

Simulate Youtube Top Loading Indicator With TopLoader.js

Description:

TopLoader.js is a small JavaScript component that lets you create an animated top progress bar to simulate the Youtube-style loading indicator.

How to use it:

1. Install the package and import the TopLoader.js as a component.

# NPM
$ npm install top-loader-service --save
import TopLoaderService from 'top-loader-service';

2. Import the necessary stylesheet.

import 'top-loader-service/TopLoaderService.css'
<!-- or -->
<link href="TopLoaderService.css" rel="stylesheet">

3. Start the top loading indicator.

TopLoaderService.start();

4. Stop the loading indicator when needed.

TopLoaderService.stop();

You Might Be Interested In:


Leave a Reply