Skip to content

Commit be74562

Browse files
coadofacebook-github-bot
authored andcommitted
Export NewAppScreen from the root (facebook#50801)
Summary: New react native projects from react-native-communit/template use components from the `NewAppScreen` which is currently not root exported: ``` import { Colors, DebugInstructions, Header, LearnMoreLinks, ReloadInstructions, } from 'react-native/Libraries/NewAppScreen'; ``` This diff adds re-export of the NewAppScreen as a namespace to state the origin of imported components clearly. Changelog: [Internal] Differential Revision: D73242541
1 parent 5fd5188 commit be74562

File tree

3 files changed

+6
-0
lines changed

3 files changed

+6
-0
lines changed

packages/react-native/Libraries/__tests__/__snapshots__/public-api-test.js.snap

+1
Original file line numberDiff line numberDiff line change
@@ -9082,6 +9082,7 @@ export type {
90829082
VirtualizedSectionListProps,
90839083
} from \\"./Libraries/Lists/VirtualizedSectionList\\";
90849084
export { default as VirtualizedSectionList } from \\"./Libraries/Lists/VirtualizedSectionList\\";
9085+
export * as NewAppScreen from \\"./Libraries/NewAppScreen\\";
90859086
export { default as AccessibilityInfo } from \\"./Libraries/Components/AccessibilityInfo/AccessibilityInfo\\";
90869087
export type {
90879088
ActionSheetIOSOptions,

packages/react-native/index.js

+3
Original file line numberDiff line numberDiff line change
@@ -238,6 +238,9 @@ module.exports = {
238238
get Networking() {
239239
return require('./Libraries/Network/RCTNetworking').default;
240240
},
241+
get NewAppScreen() {
242+
return require('./Libraries/NewAppScreen');
243+
},
241244
get PanResponder() {
242245
return require('./Libraries/Interaction/PanResponder').default;
243246
},

packages/react-native/index.js.flow

+2
Original file line numberDiff line numberDiff line change
@@ -318,6 +318,8 @@ export {default as NativeEventEmitter} from './Libraries/EventEmitter/NativeEven
318318
export {default as NativeModules} from './Libraries/BatchedBridge/NativeModules';
319319
export {default as Networking} from './Libraries/Network/RCTNetworking';
320320

321+
export * as NewAppScreen from './Libraries/NewAppScreen';
322+
321323
export type {
322324
PanResponderCallbacks,
323325
PanResponderGestureState,

0 commit comments

Comments
 (0)