Skip to content

Waypoints is a small jQuery plugin that makes it easy to execute a function whenever you scroll to an element.

License

GPL-2.0, MIT licenses found

Licenses found

GPL-2.0
GPL-license.txt
MIT
MIT-license.txt
Notifications You must be signed in to change notification settings

sunjialiang/jquery-waypoints

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jQuery Waypoints

Waypoints is a small jQuery plugin that makes it easy to execute a function whenever you scroll to an element.

$('.entry').waypoint(function() {
   alert('You have scrolled to an entry.');
});

Read the full documentation for more details on usage and customization.

Examples

Waypoints can be used as a base for several common scroll-based UI patterns. Check out these examples of:

License

Copyright (c) 2011 Caleb Troughton Dual licensed under the MIT license and GPL license.

Support

Waypoints has been tested to work with jQuery versions 1.4+ in IE6+, FF3+, Safari 4+, Chrome 6+. Other browsers and jQuery versions may work fine, but this is all I've looked at so far.

Unit tests for Waypoints are written with Jasmine and jasmine-jquery. You can run them here. If any of the tests fail, please open an issue and include the browser used, operating system, and description of the failed test.

Changelog

v1.0.2

  • Moved scroll and resize handler bindings out of load. Should play nicer with async loaders like Head JS and LABjs.
  • Fixed a 1px off error when using certain % offsets.
  • Added unit tests.

v1.0.1

  • Added $.waypoints('viewportHeight').
  • Fixed iOS bug (using the new viewportHeight method).
  • Added offset function alias: 'bottom-in-view'.

v1.0

  • Initial release.

Known Todos

  • Audit non-iOS mobile browsers.

About

Waypoints is a small jQuery plugin that makes it easy to execute a function whenever you scroll to an element.

Resources

License

GPL-2.0, MIT licenses found

Licenses found

GPL-2.0
GPL-license.txt
MIT
MIT-license.txt

Stars

Watchers

Forks

Packages

No packages published