diff options
author | Rob Loach <robloach@gmail.com> | 2014-10-07 12:05:23 -0400 |
---|---|---|
committer | Rob Loach <robloach@gmail.com> | 2014-10-07 12:05:23 -0400 |
commit | 8f1f8d4e417bf5360b57d706cb6d84a1c632ad79 (patch) | |
tree | e50f393b27fce3f4f6c999e2a882e03d5199f313 | |
parent | 79a4179e1cd4f873fe4144dcf47425e773cb07f6 (diff) | |
download | jquery-once-8f1f8d4e417bf5360b57d706cb6d84a1c632ad79.zip jquery-once-8f1f8d4e417bf5360b57d706cb6d84a1c632ad79.tar.gz jquery-once-8f1f8d4e417bf5360b57d706cb6d84a1c632ad79.tar.bz2 |
Update to 2.0.0-alpha.6 - fixes #7
-rw-r--r-- | README.md | 12 | ||||
-rw-r--r-- | bower.json | 2 | ||||
-rw-r--r-- | component.json | 2 | ||||
-rw-r--r-- | once.jquery.json | 2 | ||||
-rw-r--r-- | package.json | 4 |
5 files changed, 11 insertions, 11 deletions
@@ -39,7 +39,7 @@ be used to ensure that a function is only applied once to an element. ### [Browserify](http://browserify.org/) - Use: `require('jquery-once')` - Install: `npm install --save jquery-once` -- CDN URL: `//wzrd.in/bundle/jquery-once@2.0.0-alpha.5` +- CDN URL: `//wzrd.in/bundle/jquery-once@2.0.0-alpha.6` ### [Ender](http://ender.jit.su/) - Use: `require('jquery-once')` @@ -61,7 +61,7 @@ be used to ensure that a function is only applied once to an element. ### `.once()` ``` javascript -$('div.calendar').once('calendar', function() { +$('div.calendar').once('calendar').each(function() { // This function is only executed once for each div, even if this // code segment is executed repeatedly. }); @@ -76,7 +76,7 @@ $('div.calendar').once('calendar').click(function() { It also works without supplying a name: ``` javascript -$('div.calendar').once(function() { +$('div.calendar').once().each(function() { // This function is only executed once for each div, even if this // code segment is executed repeatedly. Other scripts can't refer // to this `once` method. The once data used to store execution are @@ -90,7 +90,7 @@ After `.once()` is used and you need to retrieve all elements that have already been executed with `.once()`, you can use the `.findOnce() function: ``` javascript -$('div.calendar').findOnce('calendar', function() { +$('div.calendar').findOnce('calendar').each(function() { // This function is called for each element that was already called "once" // with the "calendar" ID. }); @@ -102,7 +102,7 @@ It is possible to remove the `.once()` data, and iterate through each element whose once state is removed: ``` javascript -$('div.calendar').removeOnce('calendar', function() { +$('div.calendar').removeOnce('calendar').each(function() { // This function is called for each element whose once() data is removed. }); ``` @@ -174,7 +174,7 @@ No sponsors yet! Will you be the first? These amazing people have contributed code to this project: - [JohnAlbin](https://github.com/JohnAlbin) — [view contributions](https://github.com/RobLoach/jquery-once/commits?author=JohnAlbin) -- [Rob Loach](https://github.com/robloach) <robloach@gmail.com> — [view contributions](https://github.com/RobLoach/jquery-once/commits?author=robloach) +- [Rob Loach](https://github.com/RobLoach) <robloach@gmail.com> — [view contributions](https://github.com/RobLoach/jquery-once/commits?author=RobLoach) - [theodoreb](https://github.com/theodoreb) — [view contributions](https://github.com/RobLoach/jquery-once/commits?author=theodoreb) [Become a contributor!](https://github.com/RobLoach/jquery-once/blob/master/CONTRIBUTING.md#files) @@ -2,7 +2,7 @@ "name": "jquery-once", "homepage": "http://github.com/robloach/jquery-once", "description": "jQuery Once Plugin", - "version": "2.0.0-alpha.5", + "version": "2.0.0-alpha.6", "main": "jquery.once.js", "ignore": [ "*.json", diff --git a/component.json b/component.json index f78f7a9..35ffb81 100644 --- a/component.json +++ b/component.json @@ -4,7 +4,7 @@ "homepage": "http://github.com/robloach/jquery-once", "description": "Act on jQuery elements only once.", "license": "GPL-2.0", - "version": "2.0.0-alpha.5", + "version": "2.0.0-alpha.6", "keywords": [ "jquery" ], diff --git a/once.jquery.json b/once.jquery.json index f8c39ab..d8323ae 100644 --- a/once.jquery.json +++ b/once.jquery.json @@ -6,7 +6,7 @@ "jquery", "once" ], - "version": "2.0.0-alpha.5", + "version": "2.0.0-alpha.6", "author": { "name": "Rob Loach", "url": "http://robloach.net" diff --git a/package.json b/package.json index 31220ce..d54e57a 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "jquery-once", "title": "jQuery Once", "description": "Act on jQuery elements only once.", - "version": "2.0.0-alpha.5", + "version": "2.0.0-alpha.6", "keywords": [ "jquery" ], @@ -22,7 +22,7 @@ "main": "jquery.once.js", "contributors": [ "JohnAlbin (https://github.com/JohnAlbin)", - "Rob Loach <robloach@gmail.com> (https://github.com/robloach)", + "Rob Loach <robloach@gmail.com> (https://github.com/RobLoach)", "theodoreb (https://github.com/theodoreb)" ], "repository": { |