Giter Site home page Giter Site logo

infinitecarousel's Introduction

InfiniteCarousel

A simple, responsive, infinite carousel with on-demand lazy-loading, for Backbone.

This is a very simple carousel script. It's a lot less robust and full-featured than other carousels, but its approach does provide several advantages for certain use cases.

I wrote this script because I needed a responsive carousel which supported transparent, on-demand lazy loading. I wanted to be certain that users would never see a "loading" graphic or inadvertently download dozens of images they'd never see. The carousel also needed to loop infinitely in both directions.

The main difference is that other carousels are usually strongly tied to concrete DOM elements -- the elements of the carousel are already present on the page, and are turned into a carousel. InfiniteCarousel, on the other hand, starts with metadata about the carousel elements, building them from the ground up. It's a straight-up programmatic approach, and it affords you a great deal of flexibility.

InfiniteCarousel handles responsiveness with aplomb, too. Because it generates and controls the carousel's elements (rather than trying to corral them into a working carousel), it takes an amazingly elegant approach to responsive resizing. Unlike other carousels, which need to do a bunch of math to resize carousel items, InfiniteCarousel simply lets the browser do it. In other words, this thing will even be responsive in legacy versions of IE. (Not that you should be using them.)

Dependencies

infinitecarousel's People

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

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.