Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

@youngbeen/anima

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@youngbeen/anima

Anima is an easy-to-use yet light weight javascript library to animate elements in your page

npmnpm
Version
0.1.2
Version published
Weekly downloads
20
150%
Maintainers
1
Weekly downloads
 
Created
Source

[TOC]

Anima

Anima is an easy-to-use yet light weight javascript library to animate elements in your page

Features

  • Easy to use
  • Config animation time to each element differently
  • Lazy triggering (means effecient)
  • Auto revoking listeners (means effecient)

Install

Install it via npm

npm i -S '@youngbeen/anima'

Import

import anima from '@youngbeen/anima'

Usage

In html, on which element you want to animate. Add a use-anima attribute

<p use-anima>Element</p>

Then init anima in proper time (or reinit it)

anima.init()

That's all! Anima will handle the rest.

Documents

Config Animation Time

You can config animation time for each element. Add anima-time attribute to element

anima-time value is consumed with ms(milliseconds)

<p use-anima anima-time="400">Element</p>

Manually Revoke Listeners

anima.revoke()

Keywords

animation

FAQs

Package last updated on 20 Aug 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts