react 16.0.0-rc.2 → 16.0.0-rc.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/react.development.js +14 -2
- package/cjs/react.production.min.js +13 -2
- package/index.js +0 -44
- package/package.json +1 -1
- package/umd/react.development.js +13 -4
- package/umd/react.production.min.js +24 -13
package/cjs/react.development.js
CHANGED
|
@@ -1,3 +1,13 @@
|
|
|
1
|
+
/** @license React v16.0.0-rc.3
|
|
2
|
+
* react.development.js
|
|
3
|
+
*
|
|
4
|
+
* Copyright 2013-present, Facebook, Inc.
|
|
5
|
+
* All rights reserved.
|
|
6
|
+
*
|
|
7
|
+
* This source code is licensed under the BSD-style license found in the
|
|
8
|
+
* LICENSE file in the root directory of this source tree. An additional grant
|
|
9
|
+
* of patent rights can be found in the PATENTS file in the same directory.
|
|
10
|
+
*/
|
|
1
11
|
'use strict';
|
|
2
12
|
|
|
3
13
|
|
|
@@ -1002,7 +1012,7 @@ var ReactChildren_1 = ReactChildren;
|
|
|
1002
1012
|
* @providesModule ReactVersion
|
|
1003
1013
|
*/
|
|
1004
1014
|
|
|
1005
|
-
var ReactVersion = '16.0.0-rc.
|
|
1015
|
+
var ReactVersion = '16.0.0-rc.3';
|
|
1006
1016
|
|
|
1007
1017
|
/**
|
|
1008
1018
|
* Returns the first child in a collection of children and verifies that there
|
|
@@ -1688,7 +1698,9 @@ var React = {
|
|
|
1688
1698
|
version: ReactVersion,
|
|
1689
1699
|
|
|
1690
1700
|
__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED: {
|
|
1691
|
-
ReactCurrentOwner: ReactCurrentOwner_1
|
|
1701
|
+
ReactCurrentOwner: ReactCurrentOwner_1,
|
|
1702
|
+
// Used by renderers to avoid bundling object-assign twice in UMD bundles:
|
|
1703
|
+
assign: objectAssign$1
|
|
1692
1704
|
}
|
|
1693
1705
|
};
|
|
1694
1706
|
|
|
@@ -1,4 +1,15 @@
|
|
|
1
|
-
|
|
1
|
+
/*
|
|
2
|
+
React v16.0.0-rc.3
|
|
3
|
+
react.production.min.js
|
|
4
|
+
|
|
5
|
+
Copyright 2013-present, Facebook, Inc.
|
|
6
|
+
All rights reserved.
|
|
7
|
+
|
|
8
|
+
This source code is licensed under the BSD-style license found in the
|
|
9
|
+
LICENSE file in the root directory of this source tree. An additional grant
|
|
10
|
+
of patent rights can be found in the PATENTS file in the same directory.
|
|
11
|
+
*/
|
|
12
|
+
'use strict';var f=require("object-assign"),p=require("fbjs/lib/emptyObject");require("fbjs/lib/invariant");var r=require("fbjs/lib/emptyFunction");
|
|
2
13
|
function t(a){for(var b=arguments.length-1,d="Minified React error #"+a+"; visit http://facebook.github.io/react/docs/error-decoder.html?invariant\x3d"+a,e=0;e<b;e++)d+="\x26args[]\x3d"+encodeURIComponent(arguments[e+1]);b=Error(d+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings.");b.name="Invariant Violation";b.framesToPop=1;throw b;}
|
|
3
14
|
var u={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}};function v(a,b,d){this.props=a;this.context=b;this.refs=p;this.updater=d||u}v.prototype.isReactComponent={};v.prototype.setState=function(a,b){"object"!==typeof a&&"function"!==typeof a&&null!=a?t("85"):void 0;this.updater.enqueueSetState(this,a,b,"setState")};v.prototype.forceUpdate=function(a){this.updater.enqueueForceUpdate(this,a,"forceUpdate")};
|
|
4
15
|
function w(a,b,d){this.props=a;this.context=b;this.refs=p;this.updater=d||u}function x(){}x.prototype=v.prototype;var y=w.prototype=new x;y.constructor=w;f(y,v.prototype);y.isPureReactComponent=!0;function z(a,b,d){this.props=a;this.context=b;this.refs=p;this.updater=d||u}var A=z.prototype=new x;A.constructor=z;f(A,v.prototype);A.unstable_isAsyncReactComponent=!0;A.render=function(){return this.props.children};
|
|
@@ -11,4 +22,4 @@ function L(a,b,d,e){if(K.length){var c=K.pop();c.result=a;c.keyPrefix=b;c.func=d
|
|
|
11
22
|
function N(a,b,d,e){var c=typeof a;if("undefined"===c||"boolean"===c)a=null;if(null===a||"string"===c||"number"===c||"object"===c&&a.$$typeof===I)return d(e,a,""===b?"."+O(a,0):b),1;var g=0;b=""===b?".":b+":";if(Array.isArray(a))for(var k=0;k<a.length;k++){c=a[k];var m=b+O(c,k);g+=N(c,m,d,e)}else if(m=H&&a[H]||a["@@iterator"],"function"===typeof m)for(a=m.call(a),k=0;!(c=a.next()).done;)c=c.value,m=b+O(c,k++),g+=N(c,m,d,e);else"object"===c&&(d=""+a,t("31","[object Object]"===d?"object with keys {"+
|
|
12
23
|
Object.keys(a).join(", ")+"}":d,""));return g}function O(a,b){return"object"===typeof a&&null!==a&&null!=a.key?escape(a.key):b.toString(36)}function P(a,b){a.func.call(a.context,b,a.count++)}function Q(a,b,d){var e=a.result,c=a.keyPrefix;a=a.func.call(a.context,b,a.count++);Array.isArray(a)?R(a,e,d,r.thatReturnsArgument):null!=a&&(G.isValidElement(a)&&(a=G.cloneAndReplaceKey(a,c+(!a.key||b&&b.key===a.key?"":(""+a.key).replace(J,"$\x26/")+"/")+d)),e.push(a))}
|
|
13
24
|
function R(a,b,d,e,c){var g="";null!=d&&(g=(""+d).replace(J,"$\x26/")+"/");b=L(b,g,e,c);null==a||N(a,"",Q,b);M(b)}var S={forEach:function(a,b,d){if(null==a)return a;b=L(null,null,b,d);null==a||N(a,"",P,b);M(b)},map:function(a,b,d){if(null==a)return a;var e=[];R(a,e,null,b,d);return e},count:function(a){return null==a?0:N(a,"",r.thatReturnsNull,null)},toArray:function(a){var b=[];R(a,b,null,r.thatReturnsArgument);return b}};
|
|
14
|
-
module.exports={Children:{map:S.map,forEach:S.forEach,count:S.count,toArray:S.toArray,only:function(a){G.isValidElement(a)?void 0:t("143");return a}},Component:B.Component,PureComponent:B.PureComponent,unstable_AsyncComponent:B.AsyncComponent,createElement:G.createElement,cloneElement:G.cloneElement,isValidElement:G.isValidElement,createFactory:G.createFactory,version:"16.0.0-rc.
|
|
25
|
+
module.exports={Children:{map:S.map,forEach:S.forEach,count:S.count,toArray:S.toArray,only:function(a){G.isValidElement(a)?void 0:t("143");return a}},Component:B.Component,PureComponent:B.PureComponent,unstable_AsyncComponent:B.AsyncComponent,createElement:G.createElement,cloneElement:G.cloneElement,isValidElement:G.isValidElement,createFactory:G.createFactory,version:"16.0.0-rc.3",__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:{ReactCurrentOwner:C,assign:f}};
|
package/index.js
CHANGED
|
@@ -1,50 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
function testMinificationUsedDCE() {
|
|
4
|
-
if (process.env.NODE_ENV === 'development') {
|
|
5
|
-
// We expect this method only to be called in production.
|
|
6
|
-
throw new Error('This is unreachable');
|
|
7
|
-
}
|
|
8
|
-
try {
|
|
9
|
-
// use scoped variable for our initial test, in case
|
|
10
|
-
// 'top-level' mangling is not enabled.
|
|
11
|
-
var source = testMinificationUsedDCE.toString();
|
|
12
|
-
var longVariableName = true;
|
|
13
|
-
if (longVariableName && source.match(/longVariableName/g).length === 3) {
|
|
14
|
-
// We are not minified.
|
|
15
|
-
// This might be a Node environment where DCE is not expected anyway.
|
|
16
|
-
return;
|
|
17
|
-
}
|
|
18
|
-
if (source.match(/toString/g).length !== 2) {
|
|
19
|
-
// We always look for two matches:
|
|
20
|
-
// The actual occurence and then the call to 'match'
|
|
21
|
-
//
|
|
22
|
-
// We know for a fact the above line exists so there should be 2
|
|
23
|
-
// matches.
|
|
24
|
-
// Therefore the browser gave us invalid source.
|
|
25
|
-
return;
|
|
26
|
-
}
|
|
27
|
-
if (source.match(/unreachable/g).length === 2) {
|
|
28
|
-
// We always look for two matches:
|
|
29
|
-
// The actual occurence and then the call to 'match'
|
|
30
|
-
|
|
31
|
-
// Dead code elimination would have stripped that branch
|
|
32
|
-
// because it is impossible to reach in production.
|
|
33
|
-
setTimeout(function() {
|
|
34
|
-
// Ensure it gets reported to production logging
|
|
35
|
-
throw new Error(
|
|
36
|
-
'React is running in production mode, but dead code ' +
|
|
37
|
-
'elimination has not been applied. Read how to correctly ' +
|
|
38
|
-
'configure React for production: ' +
|
|
39
|
-
'https://fburl.com/react-perf-use-the-production-build'
|
|
40
|
-
);
|
|
41
|
-
});
|
|
42
|
-
}
|
|
43
|
-
} catch (e) {}
|
|
44
|
-
}
|
|
45
|
-
|
|
46
3
|
if (process.env.NODE_ENV === 'production') {
|
|
47
|
-
testMinificationUsedDCE();
|
|
48
4
|
module.exports = require('./cjs/react.production.min.js');
|
|
49
5
|
} else {
|
|
50
6
|
module.exports = require('./cjs/react.development.js');
|
package/package.json
CHANGED
package/umd/react.development.js
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* react.development.js
|
|
1
|
+
/** @license React v16.0.0-rc.3
|
|
2
|
+
* react.development.js
|
|
3
|
+
*
|
|
4
|
+
* Copyright 2013-present, Facebook, Inc.
|
|
5
|
+
* All rights reserved.
|
|
6
|
+
*
|
|
7
|
+
* This source code is licensed under the BSD-style license found in the
|
|
8
|
+
* LICENSE file in the root directory of this source tree. An additional grant
|
|
9
|
+
* of patent rights can be found in the PATENTS file in the same directory.
|
|
3
10
|
*/
|
|
4
11
|
|
|
5
12
|
(function (global, factory) {
|
|
@@ -1247,7 +1254,7 @@ var ReactChildren_1 = ReactChildren;
|
|
|
1247
1254
|
* @providesModule ReactVersion
|
|
1248
1255
|
*/
|
|
1249
1256
|
|
|
1250
|
-
var ReactVersion = '16.0.0-rc.
|
|
1257
|
+
var ReactVersion = '16.0.0-rc.3';
|
|
1251
1258
|
|
|
1252
1259
|
/**
|
|
1253
1260
|
* Returns the first child in a collection of children and verifies that there
|
|
@@ -1997,7 +2004,9 @@ var React = {
|
|
|
1997
2004
|
version: ReactVersion,
|
|
1998
2005
|
|
|
1999
2006
|
__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED: {
|
|
2000
|
-
ReactCurrentOwner: ReactCurrentOwner_1
|
|
2007
|
+
ReactCurrentOwner: ReactCurrentOwner_1,
|
|
2008
|
+
// Used by renderers to avoid bundling object-assign twice in UMD bundles:
|
|
2009
|
+
assign: index
|
|
2001
2010
|
}
|
|
2002
2011
|
};
|
|
2003
2012
|
|
|
@@ -1,13 +1,24 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
1
|
+
/*
|
|
2
|
+
React v16.0.0-rc.3
|
|
3
|
+
react.production.min.js
|
|
4
|
+
|
|
5
|
+
Copyright 2013-present, Facebook, Inc.
|
|
6
|
+
All rights reserved.
|
|
7
|
+
|
|
8
|
+
This source code is licensed under the BSD-style license found in the
|
|
9
|
+
LICENSE file in the root directory of this source tree. An additional grant
|
|
10
|
+
of patent rights can be found in the PATENTS file in the same directory.
|
|
11
|
+
*/
|
|
12
|
+
'use strict';function y(){function q(){}function n(a,b,c,d,e,f,g){return{$$typeof:J,type:a,key:b,ref:c,props:g,_owner:f}}function z(a){for(var b=arguments.length-1,c="Minified React error #"+a+"; visit http://facebook.github.io/react/docs/error-decoder.html?invariant\x3d"+a,d=0;d<b;d++)c+="\x26args[]\x3d"+encodeURIComponent(arguments[d+1]);b=Error(c+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings.");b.name="Invariant Violation";b.framesToPop=
|
|
13
|
+
1;throw b;}function r(a,b,c){this.props=a;this.context=b;this.refs=A;this.updater=c||B}function C(a,b,c){this.props=a;this.context=b;this.refs=A;this.updater=c||B}function D(){}function E(a,b,c){this.props=a;this.context=b;this.refs=A;this.updater=c||B}function v(a){return function(){return a}}function R(a){var b={"\x3d":"\x3d0",":":"\x3d2"};return"$"+(""+a).replace(/[=:]/g,function(a){return b[a]})}function K(a,b,c,d){if(w.length){var e=w.pop();e.result=a;e.keyPrefix=b;e.func=c;e.context=d;e.count=
|
|
14
|
+
0;return e}return{result:a,keyPrefix:b,func:c,context:d,count:0}}function L(a){a.result=null;a.keyPrefix=null;a.func=null;a.context=null;a.count=0;10>w.length&&w.push(a)}function u(a,b,c,d){var e=typeof a;if("undefined"===e||"boolean"===e)a=null;if(null===a||"string"===e||"number"===e||"object"===e&&a.$$typeof===S)return c(d,a,""===b?"."+F(a,0):b),1;var f=0;b=""===b?".":b+":";if(Array.isArray(a))for(var g=0;g<a.length;g++){e=a[g];var h=b+F(e,g);f+=u(e,h,c,d)}else if(h=M&&a[M]||a["@@iterator"],"function"===
|
|
15
|
+
typeof h)for(a=h.call(a),g=0;!(e=a.next()).done;)e=e.value,h=b+F(e,g++),f+=u(e,h,c,d);else"object"===e&&(c=""+a,z("31","[object Object]"===c?"object with keys {"+Object.keys(a).join(", ")+"}":c,""));return f}function F(a,b){return"object"===typeof a&&null!==a&&null!=a.key?R(a.key):b.toString(36)}function T(a,b){a.func.call(a.context,b,a.count++)}function U(a,b,c){var d=a.result,e=a.keyPrefix;a=a.func.call(a.context,b,a.count++);Array.isArray(a)?G(a,d,c,H.thatReturnsArgument):null!=a&&(t.isValidElement(a)&&
|
|
16
|
+
(a=t.cloneAndReplaceKey(a,e+(!a.key||b&&b.key===a.key?"":(""+a.key).replace(N,"$\x26/")+"/")+c)),d.push(a))}function G(a,b,c,d,e){var f="";null!=c&&(f=(""+c).replace(N,"$\x26/")+"/");b=K(b,f,d,e);null==a||u(a,"",U,b);L(b)}var O=Object.getOwnPropertySymbols,V=Object.prototype.hasOwnProperty,W=Object.prototype.propertyIsEnumerable,x=function(){try{if(!Object.assign)return!1;var a=new String("abc");a[5]="de";if("5"===Object.getOwnPropertyNames(a)[0])return!1;var b={};for(a=0;10>a;a++)b["_"+String.fromCharCode(a)]=
|
|
17
|
+
a;if("0123456789"!==Object.getOwnPropertyNames(b).map(function(a){return b[a]}).join(""))return!1;var c={};"abcdefghijklmnopqrst".split("").forEach(function(a){c[a]=a});return"abcdefghijklmnopqrst"!==Object.keys(Object.assign({},c)).join("")?!1:!0}catch(d){return!1}}()?Object.assign:function(a,b){if(null===a||void 0===a)throw new TypeError("Object.assign cannot be called with null or undefined");var c=Object(a);for(var d,e=1;e<arguments.length;e++){var f=Object(arguments[e]);for(var g in f)V.call(f,
|
|
18
|
+
g)&&(c[g]=f[g]);if(O){d=O(f);for(var h=0;h<d.length;h++)W.call(f,d[h])&&(c[d[h]]=f[d[h]])}}return c},B={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},A={};r.prototype.isReactComponent={};r.prototype.setState=function(a,b){"object"!==typeof a&&"function"!==typeof a&&null!=a?z("85"):void 0;this.updater.enqueueSetState(this,a,b,"setState")};r.prototype.forceUpdate=function(a){this.updater.enqueueForceUpdate(this,a,"forceUpdate")};
|
|
19
|
+
D.prototype=r.prototype;var k=C.prototype=new D;k.constructor=C;x(k,r.prototype);k.isPureReactComponent=!0;k=E.prototype=new D;k.constructor=E;x(k,r.prototype);k.unstable_isAsyncReactComponent=!0;k.render=function(){return this.props.children};var I={current:null},P=Object.prototype.hasOwnProperty,J="function"===typeof Symbol&&Symbol["for"]&&Symbol["for"]("react.element")||60103,Q={key:!0,ref:!0,__self:!0,__source:!0};n.createElement=function(a,b,c){var d,e={},f=null,g=null,h=null,k=null;if(null!=
|
|
20
|
+
b)for(d in void 0!==b.ref&&(g=b.ref),void 0!==b.key&&(f=""+b.key),h=void 0===b.__self?null:b.__self,k=void 0===b.__source?null:b.__source,b)P.call(b,d)&&!Q.hasOwnProperty(d)&&(e[d]=b[d]);var m=arguments.length-2;if(1===m)e.children=c;else if(1<m){for(var l=Array(m),p=0;p<m;p++)l[p]=arguments[p+2];e.children=l}if(a&&a.defaultProps)for(d in m=a.defaultProps,m)void 0===e[d]&&(e[d]=m[d]);return n(a,f,g,h,k,I.current,e)};n.createFactory=function(a){var b=n.createElement.bind(null,a);b.type=a;return b};
|
|
21
|
+
n.cloneAndReplaceKey=function(a,b){return n(a.type,b,a.ref,a._self,a._source,a._owner,a.props)};n.cloneElement=function(a,b,c){var d=x({},a.props),e=a.key,f=a.ref,g=a._self,h=a._source,k=a._owner;if(null!=b){void 0!==b.ref&&(f=b.ref,k=I.current);void 0!==b.key&&(e=""+b.key);if(a.type&&a.type.defaultProps)var m=a.type.defaultProps;for(l in b)P.call(b,l)&&!Q.hasOwnProperty(l)&&(d[l]=void 0===b[l]&&void 0!==m?m[l]:b[l])}var l=arguments.length-2;if(1===l)d.children=c;else if(1<l){m=Array(l);for(var p=
|
|
22
|
+
0;p<l;p++)m[p]=arguments[p+2];d.children=m}return n(a.type,e,f,g,h,k,d)};n.isValidElement=function(a){return"object"===typeof a&&null!==a&&a.$$typeof===J};var t=n;q.thatReturns=v;q.thatReturnsFalse=v(!1);q.thatReturnsTrue=v(!0);q.thatReturnsNull=v(null);q.thatReturnsThis=function(){return this};q.thatReturnsArgument=function(a){return a};var H=q,M="function"===typeof Symbol&&Symbol.iterator,S="function"===typeof Symbol&&Symbol["for"]&&Symbol["for"]("react.element")||60103,N=/\/+/g,w=[];return{Children:{map:function(a,
|
|
23
|
+
b,c){if(null==a)return a;var d=[];G(a,d,null,b,c);return d},forEach:function(a,b,c){if(null==a)return a;b=K(null,null,b,c);null==a||u(a,"",T,b);L(b)},count:function(a){return null==a?0:u(a,"",H.thatReturnsNull,null)},toArray:function(a){var b=[];G(a,b,null,H.thatReturnsArgument);return b},only:function(a){t.isValidElement(a)?void 0:z("143");return a}},Component:r,PureComponent:C,unstable_AsyncComponent:E,createElement:t.createElement,cloneElement:t.cloneElement,isValidElement:t.isValidElement,createFactory:t.createFactory,
|
|
24
|
+
version:"16.0.0-rc.3",__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:{ReactCurrentOwner:I,assign:x}}}"object"===typeof exports&&"undefined"!==typeof module?module.exports=y():"function"===typeof define&&define.amd?define(y):this.React=y();
|