@samitouri / QOS-React-2 / commits / 14725ba768

Clean up caller sites of instantiateReactComponent

The 2nd argument was removed since #4139.

Taeho Kim committed Dec 6, 2015 at 17:31 UTC 14725ba76887a1ceb0e722e169151e0e78ce1d95
3 files changed +4 -7
src/renderers/dom/client/ReactMount.js
+1 -1
@@ -330,7 +330,7 @@ var ReactMount = {
330 );
331
332 ReactBrowserEventEmitter.ensureScrollValueMonitoring();
333 - var componentInstance = instantiateReactComponent(nextElement, null);
333 + var componentInstance = instantiateReactComponent(nextElement);
334
335 // The initial render is synchronous but any updates that happen during
336 // rendering, in componentWillMount or componentDidMount, will be batched
src/renderers/dom/server/ReactServerRendering.js
+1 -1
@@ -41,7 +41,7 @@ function renderToStringImpl(element, makeStaticMarkup) {
41 transaction = ReactServerRenderingTransaction.getPooled(makeStaticMarkup);
42
43 return transaction.perform(function() {
44 - var componentInstance = instantiateReactComponent(element, null);
44 + var componentInstance = instantiateReactComponent(element);
45 var markup = componentInstance.mountComponent(
46 transaction,
47 null,
src/renderers/shared/reconciler/ReactChildReconciler.js
+2 -5
@@ -32,7 +32,7 @@ function instantiateChild(childInstances, child, name) {
32 );
33 }
34 if (child != null && keyUnique) {
35 - childInstances[name] = instantiateReactComponent(child, null);
35 + childInstances[name] = instantiateReactComponent(child);
36 }
37 }
38
@@ -101,10 +101,7 @@ var ReactChildReconciler = {
101 ReactReconciler.unmountComponent(prevChild, name);
102 }
103 // The child must be instantiated before it's mounted.
104 - var nextChildInstance = instantiateReactComponent(
105 - nextElement,
106 - null
107 - );
104 + var nextChildInstance = instantiateReactComponent(nextElement);
105 nextChildren[name] = nextChildInstance;
106 }
107 }