Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

animate-styles

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

animate-styles

Composable CSS Animations Built On animate.css

  • 1.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

animate-styles

Composable CSS Animations Built On animate.css

install

npm install animate-styles --save

usage

var animate = require('animate-styles')
var yo = require('yo-yo')
var el = yo`<h1 class="${animate.fadeIn}">hello</h1>`
document.body.appendChild(el)

extract the stylesheet

The stylesheet will need to be added to the document to view. Here is a way using csjs:

var animate = require('animate-styles')
var csjs = require('csjs')

var style = document.createElement('style')
style.textContent = csjs.getCss(animate)
document.head.appendChild(style)

Or check out csjs-extractify for extracting the CSS to files or csjs-injectify for injecting the CSS into the document.

using animation sets

The animations are exported as smaller sets based on animate-config.json.

var style = require('animate-styles/attention_seekers')
var yo = require('yo-yo')
var el = yo`<h1 class="${style.bounce}">bouncing</h1>`

customize the animations

var animate = require('animate-styles')
var yo = require('yo-yo')
var csjs = require('csjs')

var style = csjs`
.custom extends ${animate.bounce} {
  animation-iteration-count: infinite;
}
`
var el = yo`<h1 class="${style.custom}">animate-styles</h1>`

Keywords

FAQs

Package last updated on 01 May 2016

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc