Coder Social home page Coder Social logo

asset-async-load's Introduction

Asset Async Load

JQuery plugin that helps you load the sources of elements async to the page load by using data attributes. Also there is an option for loading responsive sources by setting all sources in the same attributes as follows:

[IMAGE|MIN_WINDOW_WIDTH], [OTHER IMAGE|OTHER_WINDOW_MIN_WIDTH], [DEFAULT_IMAGE]

Attributes

  • [data-asset-async-background-image] for background images
  • [data-asset-async-src-image] for image sources
  • [data-asset-async-src-video-source] for video sources

Examples

<img data-asset-async-src-image="test.jpg" />

<div data-asset-async-background-image="test.jpg"></div>

<video>
  <source data-asset-async-src-video-source="test.mp4"></source>
  <source data-asset-async-src-video-source="test.ogv"></source>
</video>

<img data-asset-async-src-image="[http://placehold.it/600x200|1000], [http://placehold.it/1600x400|1600], [http://placehold.it/1900x200]" alt="" />

asset-async-load's People

Contributors

liberat0r avatar

Watchers

James Cloos avatar  avatar

Forkers

sergredvil

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.