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

gifease.js

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

gifease.js

Check DOM for gif files. Load an image in its place.

  • 0.0.1
  • latest
  • npm
  • Socket score

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

image

Gifease.js

A gif performance management service.

description

Gifease.js looks at your DOM for all your images with a data-gifease attribute. If an image tag has a data-gifease attribute, it will create a click handler on the element. The handler will replace the image with the gif file on click. This will help reduce unnecessary gif loading bandwidth.

instructions

This is one way to include gifease.

  1. Include gif.js. <script src="gifease.js"></script>

  2. Instantiate gif.js. <script>gifease = new Gifease</script>

  3. There is no step 3.

example

Before click

<img src="/a/path/image.jpg" data-gifease="/a/path/animate.gif">

![Before](http://fakeimg.pl/250x150?text=Static Image)

After click

<img src="/a/path/animate.gif" data-gifease="/a/path/animate.gif">

After

Keywords

FAQs

Package last updated on 30 May 2014

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