Bump to v3.3.0.

This commit is contained in:
John-David Dalton
2015-12-16 17:46:57 -08:00
parent 3ccb5e7da3
commit f8e4370129
91 changed files with 826 additions and 401 deletions

View File

@@ -19,7 +19,9 @@ define(['../internal/baseBindAll', '../internal/baseFlatten', '../object/functio
*
* var view = {
* 'label': 'docs',
* 'onClick': function() { console.log('clicked ' + this.label); }
* 'onClick': function() {
* console.log('clicked ' + this.label);
* }
* };
*
* _.bindAll(view);

View File

@@ -12,7 +12,9 @@ define(['../internal/baseDelay'], function(baseDelay) {
* @returns {number} Returns the timer id.
* @example
*
* _.defer(function(text) { console.log(text); }, 'deferred');
* _.defer(function(text) {
* console.log(text);
* }, 'deferred');
* // logs 'deferred' after one or more milliseconds
*/
function defer(func) {

View File

@@ -13,7 +13,9 @@ define(['../internal/baseDelay'], function(baseDelay) {
* @returns {number} Returns the timer id.
* @example
*
* _.delay(function(text) { console.log(text); }, 1000, 'later');
* _.delay(function(text) {
* console.log(text);
* }, 1000, 'later');
* // => logs 'later' after one second
*/
function delay(func, wait) {

View File

@@ -1,4 +1,4 @@
define(['../internal/arrayEvery', '../lang/isFunction'], function(arrayEvery, isFunction) {
define(['../internal/arrayEvery', '../internal/baseIsFunction'], function(arrayEvery, baseIsFunction) {
/** Used as the `TypeError` message for "Functions" methods. */
var FUNC_ERROR_TEXT = 'Expected a function';
@@ -34,7 +34,7 @@ define(['../internal/arrayEvery', '../lang/isFunction'], function(arrayEvery, is
if (!length) {
return function() { return arguments[0]; };
}
if (!arrayEvery(funcs, isFunction)) {
if (!arrayEvery(funcs, baseIsFunction)) {
throw new TypeError(FUNC_ERROR_TEXT);
}
return function() {

View File

@@ -1,4 +1,4 @@
define(['../internal/arrayEvery', '../lang/isFunction'], function(arrayEvery, isFunction) {
define(['../internal/arrayEvery', '../internal/baseIsFunction'], function(arrayEvery, baseIsFunction) {
/** Used as the `TypeError` message for "Functions" methods. */
var FUNC_ERROR_TEXT = 'Expected a function';
@@ -34,7 +34,7 @@ define(['../internal/arrayEvery', '../lang/isFunction'], function(arrayEvery, is
if (fromIndex < 0) {
return function() { return arguments[0]; };
}
if (!arrayEvery(funcs, isFunction)) {
if (!arrayEvery(funcs, baseIsFunction)) {
throw new TypeError(FUNC_ERROR_TEXT);
}
return function() {

View File

@@ -26,7 +26,9 @@ define(['../internal/baseFlatten', '../internal/createWrapper'], function(baseFl
* // => ['a', 'b', 'c']
*
* var map = _.rearg(_.map, [1, 0]);
* map(function(n) { return n * 3; }, [1, 2, 3]);
* map(function(n) {
* return n * 3;
* }, [1, 2, 3]);
* // => [3, 6, 9]
*/
function rearg(func) {

View File

@@ -42,8 +42,9 @@ define(['./debounce', '../lang/isObject'], function(debounce, isObject) {
* jQuery(window).on('scroll', _.throttle(updatePosition, 100));
*
* // invoke `renewToken` when the click event is fired, but not more than once every 5 minutes
* var throttled = _.throttle(renewToken, 300000, { 'trailing': false })
* jQuery('.interactive').on('click', throttled);
* jQuery('.interactive').on('click', _.throttle(renewToken, 300000, {
* 'trailing': false
* }));
*
* // cancel a trailing throttled call
* jQuery(window).on('popstate', throttled.cancel);