()
| 9302 | var alreadyInjected = false; |
| 9303 | |
| 9304 | function inject() { |
| 9305 | if (alreadyInjected) { |
| 9306 | // TODO: This is currently true because these injections are shared between |
| 9307 | // the client and the server package. They should be built independently |
| 9308 | // and not share any injection state. Then this problem will be solved. |
| 9309 | return; |
| 9310 | } |
| 9311 | alreadyInjected = true; |
| 9312 | |
| 9313 | ReactInjection.EventEmitter.injectReactEventListener(ReactEventListener); |
| 9314 | |
| 9315 | /** |
| 9316 | * Inject modules for resolving DOM hierarchy and plugin ordering. |
| 9317 | */ |
| 9318 | ReactInjection.EventPluginHub.injectEventPluginOrder(DefaultEventPluginOrder); |
| 9319 | ReactInjection.EventPluginUtils.injectComponentTree(ReactDOMComponentTree); |
| 9320 | ReactInjection.EventPluginUtils.injectTreeTraversal(ReactDOMTreeTraversal); |
| 9321 | |
| 9322 | /** |
| 9323 | * Some important event plugins included by default (without having to require |
| 9324 | * them). |
| 9325 | */ |
| 9326 | ReactInjection.EventPluginHub.injectEventPluginsByName({ |
| 9327 | SimpleEventPlugin: SimpleEventPlugin, |
| 9328 | EnterLeaveEventPlugin: EnterLeaveEventPlugin, |
| 9329 | ChangeEventPlugin: ChangeEventPlugin, |
| 9330 | SelectEventPlugin: SelectEventPlugin, |
| 9331 | BeforeInputEventPlugin: BeforeInputEventPlugin |
| 9332 | }); |
| 9333 | |
| 9334 | ReactInjection.NativeComponent.injectGenericComponentClass(ReactDOMComponent); |
| 9335 | |
| 9336 | ReactInjection.NativeComponent.injectTextComponentClass(ReactDOMTextComponent); |
| 9337 | |
| 9338 | ReactInjection.DOMProperty.injectDOMPropertyConfig(HTMLDOMPropertyConfig); |
| 9339 | ReactInjection.DOMProperty.injectDOMPropertyConfig(SVGDOMPropertyConfig); |
| 9340 | |
| 9341 | ReactInjection.EmptyComponent.injectEmptyComponentFactory(function (instantiate) { |
| 9342 | return new ReactDOMEmptyComponent(instantiate); |
| 9343 | }); |
| 9344 | |
| 9345 | ReactInjection.Updates.injectReconcileTransaction(ReactReconcileTransaction); |
| 9346 | ReactInjection.Updates.injectBatchingStrategy(ReactDefaultBatchingStrategy); |
| 9347 | |
| 9348 | ReactInjection.Component.injectEnvironment(ReactComponentBrowserEnvironment); |
| 9349 | |
| 9350 | if ("development" !== 'production') { |
| 9351 | var url = ExecutionEnvironment.canUseDOM && window.location.href || ''; |
| 9352 | if (/[?&]react_perf\b/.test(url)) { |
| 9353 | var ReactDefaultPerf = _dereq_(58); |
| 9354 | ReactDefaultPerf.start(); |
| 9355 | } |
| 9356 | } |
| 9357 | } |
| 9358 | |
| 9359 | module.exports = { |
| 9360 | inject: inject |
nothing calls this directly
no test coverage detected
searching dependent graphs…