gifplay-js
TypeScript icon, indicating that this package has built-in type declarations

0.1.3 • Public • Published

gifplay

animated GIF player with canvas support for pausing, going frame-by-frame

Install

$ npm i gifplay-js -S

Usage

// import
import { GifPlay } from 'gifplay-js'
const url = 'xx.gif' // gif url
const canvas = document.querySelector('canvas') // canvas element
const player = new GifPlay(canvas, url)
// play gif
player.play()
// pause gif
player.pause()

API

  • play
  • pause
  • togglePlay
  • seek
  • seekFrame

Readme

Keywords

Package Sidebar

Install

npm i gifplay-js

Weekly Downloads

0

Version

0.1.3

License

MIT

Unpacked Size

56.2 kB

Total Files

9

Last publish

Collaborators

  • gnipbao