npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

beloader-animations

v1.0.1

Published

Wrapper for animeJS with nice presets to insert animated blocks and animate text, backgrounds and colors

Downloads

8

Readme

NPM

GitHub release Gzip size Build Status Coverage Status semantic-release Documentation

bitHound Overall Score bitHound Code bitHound Dependencies bitHound Dev Dependencies Known Vulnerabilities

beloader-animations

Beloader animations is a plugin for Beloader.

It loads Elementify for lightweight easy DOM mangagement and bundles the great anime.js from Julian Garnier to support animations.

It also provides some presets for displaying animated blocks, anime background colors... that may grow other time.

Installation

In browser

For usage in browser, no installation is required. Simply load plugin with Beloader.

That example will load Beloader from CDN, then load plugin and font and finally display animated block and loading message without FOUT effect.

<html>
<head>
  <title>Animation Beloader plugin Example</title>
</head>
<body style="background-color:#000">
  <style>
    .loading {
      font-family: 'Droid Sans';
      font-size: 2em;
      text-align: center;
      color: #fff;
      font-weight: bold;
      margin-top: 2em;
      text-transform: uppercase
    }
  </style>

  <script type="text/javascript" src="https://cdn.jsdelivr.net/npm/[email protected]"></script>

  <script type="text/javascript">
    var loader = new Beloader({
      defer: true
    });

    loader.fetch('plugin', {
      id: 'animations',
      name: 'animations',      
      url: 'https://cdn.jsdelivr.net/npm/beloader-animations@latest'
    }).promise.then(function() {
      elementify.load();
      loader.animations.load('BackgroundColor', function(BackgroundColor) {
        new BackgroundColor({
          targets: 'body',
          from: '#000',
          to: '#09c'
        }).start();
      });

      loader.animations.load('ThreeDotsBouncing').then(function(ThreeDotsBouncing) {
        var dots = new ThreeDotsBouncing();

        Q('body').style('backgroundColor', '#000');
        Q('body').append(dots.block);
        dots.block.width = '30%';
        dots.start();
      })
    });

    loader.fetch('font', {
      webfont: {
        google: {
          families: ['Droid Sans', 'Droid Serif']
        }
      }
    }).promise.then(function(item) {
      elementify.Q('body').prepend('<div class="loading">Loading in progress</div>');
    });
  </script>
</body>

See a demo of this example : https://cdn.rawgit.com/beloader/beloader-animations/94619414/demos/example.html

As module

As Beloader, beloader-animations is available as UMD to be embedded in wider app. Though, main beloader-animations is pretty useless as a module, each animation can be embedded separately :

import 'ThreeDotsBouncing' from 'beloader-animations/dist/animations/ThreeDotsBouncing';
//or
const ThreeDotsBouncing = require('beloader-animations/dist/animations/ThreeDotsBouncing').default;

Each animation expect Elementify and Anime to be already loaded as externals.

Preset animations

See documentation for details.