New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

timeline-events

Package Overview
Dependencies
Maintainers
1
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

timeline-events

A simple package for firing events on custom points in a timeline.

  • 1.0.5
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source

Timeline events

A simple package for firing events on custom points in a timeline.

yarn add timeline-events

Example:

import Timeline from "timeline-events";

const tl = new Timeline([
  {
    start: 0,
    duration: 2,
    cb: () => {
      console.log("Test");
    }
  },
  {
    followUp: true,
    duration: 2,
    cb: () => {
      console.log("Test 2 follow-up");
    }
  },
  {
    start: 1,
    duration: 2,
    cb: () => {
      console.log("Test 3 - but sooner then Test 2 follow-up");
    }
  }
]);

Timeline entry options

start number (in seconds)
A number to define when the callback of the entry should fire Mandatory when NOT using followUp in the next entry!

duration number
Duration until next animation. Mandatory when using followUp in the next entry!

followUp boolean
Fire immediately after the previous entry ends

cb function (mandatory)
The callback fired when reaching the startingpoint

FAQs

Package last updated on 09 Dec 2019

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