Skip to content

package.json for npm #3

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 10 additions & 3 deletions jquery.appear.js
Original file line number Diff line number Diff line change
@@ -8,7 +8,15 @@
* Copyright (c) 2012-2014 Alexander Brovikov
* Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
*/
(function($) {
(function (root, factory) {
if (typeof define === 'function' && define.amd) {
define(['jquery'], factory);
} else if (typeof module === 'object' && module.exports) {
factory(require('jquery'));
} else {
factory(root.jQuery);
}
}(this, function ($) {
$.fn.appear = function(fn, options) {

var settings = $.extend({
@@ -147,5 +155,4 @@
}
}
});

})(jQuery);
}));
19 changes: 19 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"name": "jquery.appear",
"version": "1.0.1",
"description": "jQuery plugin to call a function when an element appears",
"main": "jquery.appear.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "git://github.com/bas2k/jquery.appear.git"
},
"author": "bas2k",
"license": "MIT",
"bugs": {
"url": "https://github.com/bas2k/jquery.appear/issues"
},
"homepage": "https://github.com/bas2k/jquery.appear#readme"
}