mirror of
https://github.com/zhigang1992/react-native-web.git
synced 2026-03-30 17:34:05 +08:00
Fixes a regression introduced in the following commit to avoid directly
depending on the 'react-dom' entry file:
d65c92eea9
Injecting ReactDefaultInjection adds ~25 KB back to the UMD build.
Fix #263
36 lines
808 B
JavaScript
36 lines
808 B
JavaScript
import findNodeHandle from './modules/findNodeHandle';
|
|
import ReactDefaultInjection from 'react/lib/ReactDefaultInjection';
|
|
import { render, unmountComponentAtNode } from 'react/lib/ReactMount';
|
|
|
|
ReactDefaultInjection.inject();
|
|
|
|
// APIs
|
|
import I18nManager from './apis/I18nManager';
|
|
import StyleSheet from './apis/StyleSheet';
|
|
|
|
// components
|
|
import Image from './components/Image';
|
|
import Text from './components/Text';
|
|
import TextInput from './components/TextInput';
|
|
import View from './components/View';
|
|
|
|
// modules
|
|
import createDOMElement from './modules/createDOMElement';
|
|
|
|
const ReactNativeCore = {
|
|
createDOMElement,
|
|
findNodeHandle,
|
|
render,
|
|
unmountComponentAtNode,
|
|
// APIs
|
|
I18nManager,
|
|
StyleSheet,
|
|
// components
|
|
Image,
|
|
Text,
|
|
TextInput,
|
|
View
|
|
};
|
|
|
|
module.exports = ReactNativeCore;
|