@react-native-oh/react-native-harmony 0.72.23 → 0.72.27

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.
Files changed (44) hide show
  1. package/Libraries/Alert/Alert.harmony.js +71 -71
  2. package/Libraries/Alert/AlertManager.ts +35 -35
  3. package/Libraries/Animated/NativeAnimatedHelper.harmony.js +601 -601
  4. package/Libraries/Components/AccessibilityInfo/AccessibilityInfo.harmony.js +445 -426
  5. package/Libraries/Components/AccessibilityInfo/NativeAccessibilityManager.harmony.js +30 -0
  6. package/Libraries/Components/AccessibilityInfo/legacySendAccessibilityEvent.harmony.js +26 -0
  7. package/Libraries/Components/Button/Button.harmony.js +450 -450
  8. package/Libraries/Components/Image/Image.flow.harmony.js +53 -0
  9. package/Libraries/Components/Image/Image.harmony.js +299 -0
  10. package/Libraries/Components/Image/NativeImageLoaderHarmony.js +38 -0
  11. package/Libraries/Components/RefreshControl/RefreshControl.harmony.js +210 -208
  12. package/Libraries/Components/SafeAreaView/SafeAreaView.harmony.tsx +76 -75
  13. package/Libraries/Components/ScrollView/ScrollView.harmony.js +1951 -1930
  14. package/Libraries/Components/ScrollView/processDecelerationRate.harmony.js +24 -24
  15. package/Libraries/Components/StatusBar/NativeStatusBarManagerHarmony.js +71 -68
  16. package/Libraries/Components/StatusBar/StatusBar.harmony.js +447 -447
  17. package/Libraries/Components/TextInput/TextInput.harmony.js +1707 -1697
  18. package/Libraries/Components/TextInput/TextInputState.harmony.js +220 -220
  19. package/Libraries/Components/Touchable/TouchableHighlight.harmony.js +396 -396
  20. package/Libraries/Components/Touchable/TouchableNativeFeedback.harmony.js +364 -364
  21. package/Libraries/Components/Touchable/TouchableWithoutFeedback.harmony.js +227 -227
  22. package/Libraries/Components/View/View.harmony.js +149 -149
  23. package/Libraries/Core/setUpReactDevTools.harmony.js +93 -93
  24. package/Libraries/Image/AssetSourceResolver.harmony.ts +78 -78
  25. package/Libraries/NativeComponent/BaseViewConfig.harmony.js +337 -337
  26. package/Libraries/ReactNative/UIManager.harmony.js +210 -210
  27. package/Libraries/Settings/Settings.harmony.js +15 -15
  28. package/Libraries/Share/Share.harmony.js +174 -0
  29. package/Libraries/StyleSheet/NativePlatformColor.ts +8 -8
  30. package/Libraries/StyleSheet/PlatformColorValueTypes.harmony.ts +14 -14
  31. package/Libraries/Utilities/BackHandler.harmony.js +109 -109
  32. package/Libraries/Utilities/{NativePlatformConstantsHarmony.ts → NativePlatformConstants.harmony.ts} +8 -8
  33. package/Libraries/Utilities/Platform.d.ts +117 -117
  34. package/Libraries/Utilities/Platform.harmony.ts +33 -33
  35. package/Libraries/Utilities/createPerformanceLogger.harmony.js +328 -328
  36. package/Libraries/Vibration/Vibration.harmony.js +88 -88
  37. package/index.js +212 -202
  38. package/jest.config.js +5 -5
  39. package/metro.config.js +348 -349
  40. package/package.json +58 -55
  41. package/react-native.config.js +10 -10
  42. package/{rnoh-4.1.0.404-vmall.har → react_native_openharmony.har} +0 -0
  43. package/tsconfig.json +13 -13
  44. package/types/index.d.ts +101 -101
@@ -1,88 +1,88 @@
1
- // This implementation is based on iOS logic from file - react-native/Libraries/Vibration/Vibration.js
2
- import NativeVibration from 'react-native/Libraries/Vibration/NativeVibration'; // RNOH: patch
3
-
4
- /**
5
- * Vibration API
6
- *
7
- * See https://reactnative.dev/docs/vibration
8
- */
9
-
10
- let _vibrating: boolean = false;
11
- let _id: number = 0; // _id is necessary to prevent race condition.
12
- const _default_vibration_length = 400;
13
-
14
-
15
- function vibrateByPattern(pattern: Array<number>, repeat: boolean = false) {
16
- if (_vibrating) {
17
- return;
18
- }
19
- _vibrating = true;
20
- if (pattern.length === 0) {
21
- _vibrating = false;
22
- return;
23
- }
24
- vibrateScheduler(++_id, pattern, repeat, 0);
25
- }
26
-
27
- function vibrateScheduler(
28
- id: number,
29
- pattern: Array<number>,
30
- repeat: boolean,
31
- nextIndex: number,
32
- shouldVibrate: boolean = false, // first value in pattern is delay
33
- ) {
34
- if (!_vibrating || id !== _id) {
35
- return;
36
- }
37
- if (shouldVibrate && nextIndex < pattern.length) {
38
- NativeVibration.vibrate(pattern[nextIndex]);
39
- }
40
- if (nextIndex >= pattern.length) {
41
- if (repeat) {
42
- // $FlowFixMe[reassign-const]
43
- nextIndex = 0;
44
- shouldVibrate = true;
45
- } else {
46
- _vibrating = false;
47
- return;
48
- }
49
- }
50
- setTimeout(
51
- () => vibrateScheduler(id, pattern, repeat, nextIndex + 1, !shouldVibrate),
52
- pattern[nextIndex],
53
- );
54
- }
55
-
56
- const Vibration = {
57
- /**
58
- * Trigger a vibration with specified `pattern`.
59
- *
60
- * See https://reactnative.dev/docs/vibration#vibrate
61
- */
62
- vibrate: function (
63
- pattern: number | Array<number> = _default_vibration_length,
64
- repeat: boolean = false,
65
- ) {
66
- if (_vibrating) {
67
- return;
68
- }
69
- if (typeof pattern === 'number') {
70
- NativeVibration.vibrate(pattern);
71
- } else if (Array.isArray(pattern)) {
72
- vibrateByPattern(pattern, repeat);
73
- } else {
74
- throw new Error('Vibration pattern should be a number or array');
75
- }
76
- },
77
- /**
78
- * Stop vibration
79
- *
80
- * See https://reactnative.dev/docs/vibration#cancel
81
- */
82
- cancel: function () {
83
- _vibrating = false;
84
- NativeVibration.cancel();
85
- },
86
- };
87
-
88
- module.exports = Vibration;
1
+ // This implementation is based on iOS logic from file - react-native/Libraries/Vibration/Vibration.js
2
+ import NativeVibration from 'react-native/Libraries/Vibration/NativeVibration'; // RNOH: patch
3
+
4
+ /**
5
+ * Vibration API
6
+ *
7
+ * See https://reactnative.dev/docs/vibration
8
+ */
9
+
10
+ let _vibrating: boolean = false;
11
+ let _id: number = 0; // _id is necessary to prevent race condition.
12
+ const _default_vibration_length = 400;
13
+
14
+
15
+ function vibrateByPattern(pattern: Array<number>, repeat: boolean = false) {
16
+ if (_vibrating) {
17
+ return;
18
+ }
19
+ _vibrating = true;
20
+ if (pattern.length === 0) {
21
+ _vibrating = false;
22
+ return;
23
+ }
24
+ vibrateScheduler(++_id, pattern, repeat, 0);
25
+ }
26
+
27
+ function vibrateScheduler(
28
+ id: number,
29
+ pattern: Array<number>,
30
+ repeat: boolean,
31
+ nextIndex: number,
32
+ shouldVibrate: boolean = false, // first value in pattern is delay
33
+ ) {
34
+ if (!_vibrating || id !== _id) {
35
+ return;
36
+ }
37
+ if (shouldVibrate && nextIndex < pattern.length) {
38
+ NativeVibration.vibrate(pattern[nextIndex]);
39
+ }
40
+ if (nextIndex >= pattern.length) {
41
+ if (repeat) {
42
+ // $FlowFixMe[reassign-const]
43
+ nextIndex = 0;
44
+ shouldVibrate = true;
45
+ } else {
46
+ _vibrating = false;
47
+ return;
48
+ }
49
+ }
50
+ setTimeout(
51
+ () => vibrateScheduler(id, pattern, repeat, nextIndex + 1, !shouldVibrate),
52
+ pattern[nextIndex],
53
+ );
54
+ }
55
+
56
+ const Vibration = {
57
+ /**
58
+ * Trigger a vibration with specified `pattern`.
59
+ *
60
+ * See https://reactnative.dev/docs/vibration#vibrate
61
+ */
62
+ vibrate: function (
63
+ pattern: number | Array<number> = _default_vibration_length,
64
+ repeat: boolean = false,
65
+ ) {
66
+ if (_vibrating) {
67
+ return;
68
+ }
69
+ if (typeof pattern === 'number') {
70
+ NativeVibration.vibrate(pattern);
71
+ } else if (Array.isArray(pattern)) {
72
+ vibrateByPattern(pattern, repeat);
73
+ } else {
74
+ throw new Error('Vibration pattern should be a number or array');
75
+ }
76
+ },
77
+ /**
78
+ * Stop vibration
79
+ *
80
+ * See https://reactnative.dev/docs/vibration#cancel
81
+ */
82
+ cancel: function () {
83
+ _vibrating = false;
84
+ NativeVibration.cancel();
85
+ },
86
+ };
87
+
88
+ module.exports = Vibration;
package/index.js CHANGED
@@ -1,202 +1,212 @@
1
- module.exports = {
2
- get AccessibilityInfo() {
3
- return require('./Libraries/Components/AccessibilityInfo/AccessibilityInfo')
4
- .default;
5
- },
6
- get ActivityIndicator() {
7
- return require('react-native/Libraries/Components/ActivityIndicator/ActivityIndicator')
8
- .default;
9
- },
10
- get Alert() {
11
- return require('./Libraries/Alert/Alert.harmony');
12
- },
13
- get Animated() {
14
- return require('react-native/Libraries/Animated/Animated').default;
15
- },
16
- get Appearance() {
17
- return require('react-native/Libraries/Utilities/Appearance');
18
- },
19
- get AppRegistry() {
20
- return require('react-native/Libraries/ReactNative/AppRegistry');
21
- },
22
- get AppState() {
23
- return require('react-native/Libraries/AppState/AppState');
24
- },
25
- get BackHandler() {
26
- return require('./Libraries/Utilities/BackHandler');
27
- },
28
- get Button() {
29
- return require('./Libraries/Components/Button/Button');
30
- },
31
- get DevSettings() {
32
- return require('react-native/Libraries/Utilities/DevSettings');
33
- },
34
- get Dimensions() {
35
- return require('react-native/Libraries/Utilities/Dimensions').default;
36
- },
37
- get DeviceEventEmitter() {
38
- return require('react-native/Libraries/EventEmitter/RCTDeviceEventEmitter')
39
- .default;
40
- },
41
- get DrawerLayoutAndroid() {
42
- return require('react-native/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid');
43
- },
44
- get Easing() {
45
- return require('react-native/Libraries/Animated/Easing').default;
46
- },
47
- get findNodeHandle() {
48
- return require('react-native/Libraries/ReactNative/RendererProxy')
49
- .findNodeHandle;
50
- },
51
- get FlatList() {
52
- return require('react-native/Libraries/Lists/FlatList');
53
- },
54
- get Image() {
55
- return require('react-native/Libraries/Image/Image');
56
- },
57
- get ImageBackground() {
58
- return require('react-native/Libraries/Image/ImageBackground');
59
- },
60
- get I18nManager() {
61
- return require('react-native/Libraries/ReactNative/I18nManager');
62
- },
63
- get LayoutAnimation() {
64
- return require('react-native/Libraries/LayoutAnimation/LayoutAnimation');
65
- },
66
- get Linking() {
67
- return require('react-native/Libraries/Linking/Linking');
68
- },
69
- get Modal() {
70
- return require('react-native/Libraries/Modal/Modal');
71
- },
72
- get Keyboard() {
73
- return require('react-native/Libraries/Components/Keyboard/Keyboard');
74
- },
75
- get KeyboardAvoidingView() {
76
- return require('react-native/Libraries/Components/Keyboard/KeyboardAvoidingView')
77
- .default;
78
- },
79
- get NativeEventEmitter() {
80
- return require('react-native/Libraries/EventEmitter/NativeEventEmitter')
81
- .default;
82
- },
83
- get NativeModules() {
84
- return require('react-native/Libraries/BatchedBridge/NativeModules');
85
- },
86
- get PixelRatio() {
87
- return require('react-native/Libraries/Utilities/PixelRatio').default;
88
- },
89
- get Platform() {
90
- return require('./Libraries/Utilities/Platform');
91
- },
92
- get PlatformColor() {
93
- return require('./Libraries/StyleSheet/PlatformColorValueTypes')
94
- .PlatformColor;
95
- },
96
- get Pressable() {
97
- return require('react-native/Libraries/Components/Pressable/Pressable')
98
- .default;
99
- },
100
- get RefreshControl() {
101
- return require('./Libraries/Components/RefreshControl/RefreshControl');
102
- },
103
- get requireNativeComponent() {
104
- return require('react-native/Libraries/ReactNative/requireNativeComponent')
105
- .default;
106
- },
107
- get RootTagContext() {
108
- return require('react-native/Libraries/ReactNative/RootTag').RootTagContext;
109
- },
110
- get SafeAreaView() {
111
- return require('./Libraries/Components/SafeAreaView/SafeAreaView').default;
112
- },
113
- get Share() {
114
- return require('react-native/Libraries/Share/Share');
115
- },
116
- get ScrollView() {
117
- return require('./Libraries/Components/ScrollView/ScrollView');
118
- },
119
- get StatusBar() {
120
- return require('./Libraries/Components/StatusBar/StatusBar.harmony');
121
- },
122
- get StyleSheet() {
123
- return require('react-native/Libraries/StyleSheet/StyleSheet');
124
- },
125
- get Switch() {
126
- return require('react-native/Libraries/Components/Switch/Switch').default;
127
- },
128
- get Text() {
129
- return require('react-native/Libraries/Text/Text');
130
- },
131
- get TextInput() {
132
- return require('./Libraries/Components/TextInput/TextInput.harmony');
133
- },
134
- get ToastAndroid() {
135
- return require('react-native/Libraries/Components/ToastAndroid/ToastAndroid.android');
136
- },
137
- get Touchable() {
138
- return require('react-native/Libraries/Components/Touchable/Touchable');
139
- },
140
- get TouchableHighlight() {
141
- return require('./Libraries/Components/Touchable/TouchableHighlight');
142
- },
143
- get TouchableNativeFeedback() {
144
- return require('./Libraries/Components/Touchable/TouchableNativeFeedback');
145
- },
146
- get TouchableOpacity() {
147
- return require('react-native/Libraries/Components/Touchable/TouchableOpacity');
148
- },
149
- get TouchableWithoutFeedback() {
150
- return require('./Libraries/Components/Touchable/TouchableWithoutFeedback');
151
- },
152
- get TurboModuleRegistry() {
153
- return require('react-native/Libraries/TurboModule/TurboModuleRegistry');
154
- },
155
- get UIManager() {
156
- return require('./Libraries/ReactNative/UIManager');
157
- },
158
- get useAnimatedValue() {
159
- return require('react-native/Libraries/Animated/useAnimatedValue').default;
160
- },
161
- get useColorScheme() {
162
- return require('react-native/Libraries/Utilities/useColorScheme').default;
163
- },
164
- get useWindowDimensions() {
165
- return require('react-native/Libraries/Utilities/useWindowDimensions')
166
- .default;
167
- },
168
- get View() {
169
- return require('./Libraries/Components/View/View');
170
- },
171
- get InteractionManager() {
172
- return require('react-native/Libraries/Interaction/InteractionManager');
173
- },
174
- get PanResponder() {
175
- return require('react-native/Libraries/Interaction/PanResponder').default;
176
- },
177
- get processColor() {
178
- return require('react-native/Libraries/StyleSheet/processColor').default;
179
- },
180
- get SectionList() {
181
- return require('react-native/Libraries/Lists/SectionList').default;
182
- },
183
- get Vibration() {
184
- return require('./Libraries/Vibration/Vibration');
185
- },
186
- get VirtualizedList() {
187
- return require('react-native/Libraries/Lists/VirtualizedList');
188
- },
189
- // BEGIN: react-native-harmony specific exports
190
- get registerViewConfig() {
191
- return require('react-native/Libraries/Renderer/shims/ReactNativeViewConfigRegistry')
192
- .register;
193
- },
194
- get ReactNativeViewAttributes() {
195
- return require('react-native/Libraries/Components/View/ReactNativeViewAttributes');
196
- },
197
- get dispatchCommand() {
198
- return require('react-native/Libraries/Renderer/shims/ReactNative')
199
- .dispatchCommand;
200
- },
201
- // END: react-native-harmony specific exports
202
- };
1
+ module.exports = {
2
+ get AccessibilityInfo() {
3
+ return require('./Libraries/Components/AccessibilityInfo/AccessibilityInfo')
4
+ .default;
5
+ },
6
+ get ActivityIndicator() {
7
+ return require('react-native/Libraries/Components/ActivityIndicator/ActivityIndicator')
8
+ .default;
9
+ },
10
+ get Alert() {
11
+ return require('./Libraries/Alert/Alert.harmony');
12
+ },
13
+ get Animated() {
14
+ return require('react-native/Libraries/Animated/Animated').default;
15
+ },
16
+ get Appearance() {
17
+ return require('react-native/Libraries/Utilities/Appearance');
18
+ },
19
+ get AppRegistry() {
20
+ return require('react-native/Libraries/ReactNative/AppRegistry');
21
+ },
22
+ get AppState() {
23
+ return require('react-native/Libraries/AppState/AppState');
24
+ },
25
+ get BackHandler() {
26
+ return require('./Libraries/Utilities/BackHandler');
27
+ },
28
+ get Button() {
29
+ return require('./Libraries/Components/Button/Button');
30
+ },
31
+ get DevSettings() {
32
+ return require('react-native/Libraries/Utilities/DevSettings');
33
+ },
34
+ get Dimensions() {
35
+ return require('react-native/Libraries/Utilities/Dimensions').default;
36
+ },
37
+ get DeviceEventEmitter() {
38
+ return require('react-native/Libraries/EventEmitter/RCTDeviceEventEmitter')
39
+ .default;
40
+ },
41
+ get DrawerLayoutAndroid() {
42
+ return require('react-native/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid');
43
+ },
44
+ get Easing() {
45
+ return require('react-native/Libraries/Animated/Easing').default;
46
+ },
47
+ get findNodeHandle() {
48
+ return require('react-native/Libraries/ReactNative/RendererProxy')
49
+ .findNodeHandle;
50
+ },
51
+ get FlatList() {
52
+ return require('react-native/Libraries/Lists/FlatList');
53
+ },
54
+ get Image() {
55
+ return require('./Libraries/Components/Image/Image');
56
+ },
57
+ get ImageBackground() {
58
+ return require('react-native/Libraries/Image/ImageBackground');
59
+ },
60
+ get I18nManager() {
61
+ return require('react-native/Libraries/ReactNative/I18nManager');
62
+ },
63
+ get LayoutAnimation() {
64
+ return require('react-native/Libraries/LayoutAnimation/LayoutAnimation');
65
+ },
66
+ get Linking() {
67
+ return require('react-native/Libraries/Linking/Linking');
68
+ },
69
+ get LogBox() {
70
+ return require('react-native/Libraries/LogBox/LogBox').default;
71
+ },
72
+ get Modal() {
73
+ return require('react-native/Libraries/Modal/Modal');
74
+ },
75
+ get Keyboard() {
76
+ return require('react-native/Libraries/Components/Keyboard/Keyboard');
77
+ },
78
+ get KeyboardAvoidingView() {
79
+ return require('react-native/Libraries/Components/Keyboard/KeyboardAvoidingView')
80
+ .default;
81
+ },
82
+ get NativeEventEmitter() {
83
+ return require('react-native/Libraries/EventEmitter/NativeEventEmitter')
84
+ .default;
85
+ },
86
+ get NativeModules() {
87
+ return require('react-native/Libraries/BatchedBridge/NativeModules');
88
+ },
89
+ get PixelRatio() {
90
+ return require('react-native/Libraries/Utilities/PixelRatio').default;
91
+ },
92
+ get Platform() {
93
+ return require('./Libraries/Utilities/Platform');
94
+ },
95
+ get PlatformColor() {
96
+ return require('./Libraries/StyleSheet/PlatformColorValueTypes')
97
+ .PlatformColor;
98
+ },
99
+ get Pressable() {
100
+ return require('react-native/Libraries/Components/Pressable/Pressable')
101
+ .default;
102
+ },
103
+ get RefreshControl() {
104
+ return require('./Libraries/Components/RefreshControl/RefreshControl');
105
+ },
106
+ get requireNativeComponent() {
107
+ return require('react-native/Libraries/ReactNative/requireNativeComponent')
108
+ .default;
109
+ },
110
+ get RootTagContext() {
111
+ return require('react-native/Libraries/ReactNative/RootTag').RootTagContext;
112
+ },
113
+ get SafeAreaView() {
114
+ return require('./Libraries/Components/SafeAreaView/SafeAreaView').default;
115
+ },
116
+ get Share() {
117
+ return require('./Libraries/Share/Share');
118
+ },
119
+ get ScrollView() {
120
+ return require('./Libraries/Components/ScrollView/ScrollView');
121
+ },
122
+ get StatusBar() {
123
+ return require('./Libraries/Components/StatusBar/StatusBar.harmony');
124
+ },
125
+ get StyleSheet() {
126
+ return require('react-native/Libraries/StyleSheet/StyleSheet');
127
+ },
128
+ get Switch() {
129
+ return require('react-native/Libraries/Components/Switch/Switch').default;
130
+ },
131
+ get Systrace() {
132
+ return require('react-native/Libraries/Performance/Systrace');
133
+ },
134
+ get Text() {
135
+ return require('react-native/Libraries/Text/Text');
136
+ },
137
+ get TextInput() {
138
+ return require('./Libraries/Components/TextInput/TextInput.harmony');
139
+ },
140
+ get ToastAndroid() {
141
+ return require('react-native/Libraries/Components/ToastAndroid/ToastAndroid.android');
142
+ },
143
+ get Touchable() {
144
+ return require('react-native/Libraries/Components/Touchable/Touchable');
145
+ },
146
+ get TouchableHighlight() {
147
+ return require('./Libraries/Components/Touchable/TouchableHighlight');
148
+ },
149
+ get TouchableNativeFeedback() {
150
+ return require('./Libraries/Components/Touchable/TouchableNativeFeedback');
151
+ },
152
+ get TouchableOpacity() {
153
+ return require('react-native/Libraries/Components/Touchable/TouchableOpacity');
154
+ },
155
+ get TouchableWithoutFeedback() {
156
+ return require('./Libraries/Components/Touchable/TouchableWithoutFeedback');
157
+ },
158
+ get TurboModuleRegistry() {
159
+ return require('react-native/Libraries/TurboModule/TurboModuleRegistry');
160
+ },
161
+ get UIManager() {
162
+ return require('./Libraries/ReactNative/UIManager');
163
+ },
164
+ get unstable_batchedUpdates() {
165
+ return require('react-native/Libraries/ReactNative/RendererProxy')
166
+ .unstable_batchedUpdates;
167
+ },
168
+ get useAnimatedValue() {
169
+ return require('react-native/Libraries/Animated/useAnimatedValue').default;
170
+ },
171
+ get useColorScheme() {
172
+ return require('react-native/Libraries/Utilities/useColorScheme').default;
173
+ },
174
+ get useWindowDimensions() {
175
+ return require('react-native/Libraries/Utilities/useWindowDimensions')
176
+ .default;
177
+ },
178
+ get View() {
179
+ return require('./Libraries/Components/View/View');
180
+ },
181
+ get InteractionManager() {
182
+ return require('react-native/Libraries/Interaction/InteractionManager');
183
+ },
184
+ get PanResponder() {
185
+ return require('react-native/Libraries/Interaction/PanResponder').default;
186
+ },
187
+ get processColor() {
188
+ return require('react-native/Libraries/StyleSheet/processColor').default;
189
+ },
190
+ get SectionList() {
191
+ return require('react-native/Libraries/Lists/SectionList').default;
192
+ },
193
+ get Vibration() {
194
+ return require('./Libraries/Vibration/Vibration');
195
+ },
196
+ get VirtualizedList() {
197
+ return require('react-native/Libraries/Lists/VirtualizedList');
198
+ },
199
+ // BEGIN: react-native-harmony specific exports
200
+ get registerViewConfig() {
201
+ return require('react-native/Libraries/Renderer/shims/ReactNativeViewConfigRegistry')
202
+ .register;
203
+ },
204
+ get ReactNativeViewAttributes() {
205
+ return require('react-native/Libraries/Components/View/ReactNativeViewAttributes');
206
+ },
207
+ get dispatchCommand() {
208
+ return require('react-native/Libraries/Renderer/shims/ReactNative')
209
+ .dispatchCommand;
210
+ },
211
+ // END: react-native-harmony specific exports
212
+ };
package/jest.config.js CHANGED
@@ -1,6 +1,6 @@
1
- /** @type {import('ts-jest').JestConfigWithTsJest} */
2
- module.exports = {
3
- preset: 'ts-jest',
4
- testEnvironment: 'node',
5
- rootDir: "./tests/"
1
+ /** @type {import('ts-jest').JestConfigWithTsJest} */
2
+ module.exports = {
3
+ preset: 'ts-jest',
4
+ testEnvironment: 'node',
5
+ rootDir: "./tests/"
6
6
  };