Skip to content

Commit

Permalink
WIP Fix issues/bugs introduced by merge conflict resolution
Browse files Browse the repository at this point in the history
**what is the change?:**
NOTE: There are still bugs here, we will need at least a few more fixes.

A couple of bugs and holes were introduced when cherry-picking #9232 onto the 15.6 branch. This fixes them.

**why make this change?:**
To keep tests passing and get this change working.

**test plan:**
`yarn test`

**issue:**
#9398
  • Loading branch information
flarnie committed May 25, 2017
1 parent 4beb610 commit ba6b6fd
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 410 deletions.
18 changes: 5 additions & 13 deletions src/isomorphic/React.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,16 @@
'use strict';

var ReactChildren = require('ReactChildren');
var ReactClass = require('ReactClass');
var ReactComponent = require('ReactComponent');
var ReactPureComponent = require('ReactPureComponent');
var ReactClass = require('ReactClass');
var ReactDOMFactories = require('ReactDOMFactories');
var ReactElement = require('ReactElement');
var ReactPropTypes = require('ReactPropTypes');
var ReactVersion = require('ReactVersion');

var onlyChild = require('onlyChild');
var warning = require('warning');

var createElement = ReactElement.createElement;
var createFactory = ReactElement.createFactory;
Expand Down Expand Up @@ -55,16 +56,6 @@ if (__DEV__) {
warnedForSpread = true;
return Object.assign.apply(null, arguments);
};

createMixin = function(mixin) {
lowPriorityWarning(
warnedForCreateMixin,
'React.createMixin is deprecated and should not be used. You ' +
'can use this mixin directly instead.',
);
warnedForCreateMixin = true;
return mixin;
};
}

var React = {
Expand Down Expand Up @@ -102,8 +93,9 @@ var React = {
__spread: __spread,
};

// TODO: Fix tests so that this deprecation warning doesn't cause failures.
if (__DEV__) {
let warnedForCreateMixin = false;
let warnedForCreateClass = false;
if (canDefineProperty) {
Object.defineProperty(React, 'PropTypes', {
get() {
Expand All @@ -127,7 +119,7 @@ if (__DEV__) {
'drop-in replacement.',
);
didWarnPropTypesDeprecated = true;
return ReactPropTypes;
return ReactClass.createClass;
},
});
}
Expand Down
Loading

0 comments on commit ba6b6fd

Please sign in to comment.