Giter Club home page Giter Club logo

clever-infinite-scroll's Introduction

Clever Infinite Scroll

This is another Infinite Scroll jQuery plugin but little bit clever.

  • Please implement it in page footer or something common element
  • It is super simple, it might work in Wordpress and other CMSs

Features

  • Infinite Scroll
    • Only you need a few elements to make it active
    • You can customize the selector names
    • Of course, contents are loaded by Ajax
  • Change URL
    • The URL and page title will be changed automatically
    • It leaves History that which contents you have seen in your browser
    • It will work for both scrolling up & down
    • By offset option, you can set the offset distance for fetching next page. Default is window's height

That's it. Pretty simple, Eh?

Project models

It should look like...

Outcomes

Users (Thanks!)

clever-infinite-scroll's People

Contributors

irineujunior avatar jurecuhalev avatar wataruoguchi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

clever-infinite-scroll's Issues

Replacing TITLES

Noticing that all the titles on my pages get replaced when running this script. I commented out the code that is doing it, but wanted to pass along the info.

Basically, if anything else in the markup has a title tag (a link, svg, etc) it gets replaced in the dom with generated titles that make very little sense.

Multiple items with "active" class

I've applied your latest update that includes adding the "active" class within changeTitleAndURL.

However, I am currently experiencing an issue where if the offset loads the next item without scrolling to it, both the viewable item and the next item have the "active" class...

Indicate active content

Is it possible to add an "active" class to the contentSelector which is currently in view?

I imagine something tied to the changeTitleAndURL function?

Breaks with Overflow:Auto on Html, Body

Great plugin, seems on par with Infinite Ajax Scroll. However, both run into the same issue if you use the following CSS:

html, body {
    height: 100%;
    width: 100%;
    overflow: auto;
}

This prevents the JS from loading anything.

You have to hit back button twice to go back

First of all, I want to thank you for your work -- it saved me a lot of time. But there is one issue with the project -- when this library is active in a page, and you visit a link and want to go back, you have to click browser's back button twice.
Any ideas on why this happens?

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.