Skip to content

Instantly share code, notes, and snippets.

View riix's full-sized avatar

Park, Soon-Ghil riix

View GitHub Profile
@d0minicw0ng
d0minicw0ng / jquery.onvisible.js
Last active July 7, 2016 01:01
jquery.onvisible.js
/**
* function $.fn.onVisible runs callback function once the specified element is visible.
* callback: A function to execute at the time when the element is visible.
* example: $(selector).onVisible(callback);
*/
(function($) {
$.fn.onVisible = function (callback) {
var self = this;
@inorganik
inorganik / countUp-jquery.js
Last active February 10, 2025 14:49
A CountUp extension for jQuery
// Dependency: CountUp.js: https://github.com/inorganik/CountUp.js
(function ($) {
$.fn.countup = function (params) {
// make sure dependency is present
if (typeof CountUp !== 'function') {
console.error('countUp.js is a required dependency of countUp-jquery.js.');
return;
}