New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

transient

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

transient - npm Package Compare versions

Comparing version
1.0.0
to
1.0.1
+32
README.md
# Transient
A simple and minimal animation loop. Consistant frame rate is attempted with independant progress timing and requestAnimationFrame. This library is great for simple transition animations, thus the name, but can also be used to complex animations.
Usage:
```javascript
var animation = require('transient');
var el = document.getElementById('.my-element');
// Create the animation
var fadeIn = new animation({
duration: 1500, // 1.5 seconds
draw: function(progress) {
// progress is an integer between 0 and 1
el.style.opacity = progress;
}
});
// Start the animation
fadeIn.start();
```
Options:
- `duration`: The animation duration in milliseconds. default: `5000`
- `fps`: Consistant frames per second for the animation. default: `60`
- `loop`: Should the animation loop? default: `false`
- `draw`: The draw function which is called for each loop.
- `onEnd`: A function to call when the animation is finished.
- `onCancel`: A function to call when the animation is canceled. If this is not specified it will call the `onEnd` function
+1
-1
{
"name": "transient",
"version": "1.0.0",
"version": "1.0.1",
"description": "An animation loop implementation",

@@ -5,0 +5,0 @@ "main": "index.js",