aboutsummaryrefslogtreecommitdiff
path: root/node_modules/fbjs
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/fbjs')
-rw-r--r--node_modules/fbjs/CHANGELOG.md16
-rw-r--r--node_modules/fbjs/lib/Deferred.js6
-rw-r--r--node_modules/fbjs/lib/Deferred.js.flow6
-rw-r--r--node_modules/fbjs/lib/EventListener.js15
-rw-r--r--node_modules/fbjs/lib/EventListener.js.flow15
-rw-r--r--node_modules/fbjs/lib/warning.js66
-rw-r--r--node_modules/fbjs/package.json2
7 files changed, 63 insertions, 63 deletions
diff --git a/node_modules/fbjs/CHANGELOG.md b/node_modules/fbjs/CHANGELOG.md
index 051e343eb..dc1c52524 100644
--- a/node_modules/fbjs/CHANGELOG.md
+++ b/node_modules/fbjs/CHANGELOG.md
@@ -1,6 +1,22 @@
## [Unreleased]
+## [0.8.14] - 2017-07-25
+
+### Removed
+- Flow annotations for `keyMirror` module. The annotation generates a syntax error after being re-printed by Babel.
+
+
+## [0.8.13] - 2017-07-25
+
+### Added
+- Flow annotations for `keyMirror` module.
+
+### Fixed
+- Fixed strict argument arity issues with `Deferred` module.
+- Corrected License header in `EventListener`.
+
+
## [0.8.12] - 2017-03-29
### Fixed
diff --git a/node_modules/fbjs/lib/Deferred.js b/node_modules/fbjs/lib/Deferred.js
index bfc358580..f2fa6ceae 100644
--- a/node_modules/fbjs/lib/Deferred.js
+++ b/node_modules/fbjs/lib/Deferred.js
@@ -52,15 +52,15 @@ var Deferred = function () {
this._reject(reason);
};
- Deferred.prototype["catch"] = function _catch() {
+ Deferred.prototype["catch"] = function _catch(onReject) {
return Promise.prototype["catch"].apply(this._promise, arguments);
};
- Deferred.prototype.then = function then() {
+ Deferred.prototype.then = function then(onFulfill, onReject) {
return Promise.prototype.then.apply(this._promise, arguments);
};
- Deferred.prototype.done = function done() {
+ Deferred.prototype.done = function done(onFulfill, onReject) {
// Embed the polyfill for the non-standard Promise.prototype.done so that
// users of the open source fbjs don't need a custom lib for Promise
var promise = arguments.length ? this._promise.then.apply(this._promise, arguments) : this._promise;
diff --git a/node_modules/fbjs/lib/Deferred.js.flow b/node_modules/fbjs/lib/Deferred.js.flow
index aaad67b5c..16aa3429f 100644
--- a/node_modules/fbjs/lib/Deferred.js.flow
+++ b/node_modules/fbjs/lib/Deferred.js.flow
@@ -48,15 +48,15 @@ class Deferred<Tvalue, Treason> {
this._reject(reason);
}
- catch(): Promise<any> {
+ catch(onReject?: ?(error: any) => mixed): Promise<any> {
return Promise.prototype.catch.apply(this._promise, arguments);
}
- then(): Promise<any> {
+ then(onFulfill?: ?(value: any) => mixed, onReject?: ?(error: any) => mixed): Promise<any> {
return Promise.prototype.then.apply(this._promise, arguments);
}
- done(): void {
+ done(onFulfill?: ?(value: any) => mixed, onReject?: ?(error: any) => mixed): void {
// Embed the polyfill for the non-standard Promise.prototype.done so that
// users of the open source fbjs don't need a custom lib for Promise
const promise = arguments.length ? this._promise.then.apply(this._promise, arguments) : this._promise;
diff --git a/node_modules/fbjs/lib/EventListener.js b/node_modules/fbjs/lib/EventListener.js
index c20a23a13..a9fc97ca4 100644
--- a/node_modules/fbjs/lib/EventListener.js
+++ b/node_modules/fbjs/lib/EventListener.js
@@ -2,18 +2,11 @@
/**
* Copyright (c) 2013-present, Facebook, Inc.
+ * All rights reserved.
*
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * This source code is licensed under the BSD-style license found in the
+ * LICENSE file in the root directory of this source tree. An additional grant
+ * of patent rights can be found in the PATENTS file in the same directory.
*
* @typechecks
*/
diff --git a/node_modules/fbjs/lib/EventListener.js.flow b/node_modules/fbjs/lib/EventListener.js.flow
index 1f566665d..15f89a058 100644
--- a/node_modules/fbjs/lib/EventListener.js.flow
+++ b/node_modules/fbjs/lib/EventListener.js.flow
@@ -1,17 +1,10 @@
/**
* Copyright (c) 2013-present, Facebook, Inc.
+ * All rights reserved.
*
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * This source code is licensed under the BSD-style license found in the
+ * LICENSE file in the root directory of this source tree. An additional grant
+ * of patent rights can be found in the PATENTS file in the same directory.
*
* @providesModule EventListener
* @typechecks
diff --git a/node_modules/fbjs/lib/warning.js b/node_modules/fbjs/lib/warning.js
index 502bb610d..141c2c6a9 100644
--- a/node_modules/fbjs/lib/warning.js
+++ b/node_modules/fbjs/lib/warning.js
@@ -22,45 +22,43 @@ var emptyFunction = require('./emptyFunction');
var warning = emptyFunction;
if (process.env.NODE_ENV !== 'production') {
- (function () {
- var printWarning = function printWarning(format) {
- for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
- args[_key - 1] = arguments[_key];
- }
-
- var argIndex = 0;
- var message = 'Warning: ' + format.replace(/%s/g, function () {
- return args[argIndex++];
- });
- if (typeof console !== 'undefined') {
- console.error(message);
- }
- try {
- // --- Welcome to debugging React ---
- // This error was thrown as a convenience so that you can use this stack
- // to find the callsite that caused this warning to fire.
- throw new Error(message);
- } catch (x) {}
- };
+ var printWarning = function printWarning(format) {
+ for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
+ args[_key - 1] = arguments[_key];
+ }
- warning = function warning(condition, format) {
- if (format === undefined) {
- throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument');
- }
+ var argIndex = 0;
+ var message = 'Warning: ' + format.replace(/%s/g, function () {
+ return args[argIndex++];
+ });
+ if (typeof console !== 'undefined') {
+ console.error(message);
+ }
+ try {
+ // --- Welcome to debugging React ---
+ // This error was thrown as a convenience so that you can use this stack
+ // to find the callsite that caused this warning to fire.
+ throw new Error(message);
+ } catch (x) {}
+ };
- if (format.indexOf('Failed Composite propType: ') === 0) {
- return; // Ignore CompositeComponent proptype check.
- }
+ warning = function warning(condition, format) {
+ if (format === undefined) {
+ throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument');
+ }
- if (!condition) {
- for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) {
- args[_key2 - 2] = arguments[_key2];
- }
+ if (format.indexOf('Failed Composite propType: ') === 0) {
+ return; // Ignore CompositeComponent proptype check.
+ }
- printWarning.apply(undefined, [format].concat(args));
+ if (!condition) {
+ for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) {
+ args[_key2 - 2] = arguments[_key2];
}
- };
- })();
+
+ printWarning.apply(undefined, [format].concat(args));
+ }
+ };
}
module.exports = warning; \ No newline at end of file
diff --git a/node_modules/fbjs/package.json b/node_modules/fbjs/package.json
index 8b03c3451..0f1a2d6dd 100644
--- a/node_modules/fbjs/package.json
+++ b/node_modules/fbjs/package.json
@@ -1,6 +1,6 @@
{
"name": "fbjs",
- "version": "0.8.12",
+ "version": "0.8.14",
"description": "A collection of utility libraries used by other Facebook JS projects",
"main": "index.js",
"repository": "facebook/fbjs",