Skip to content

Commit 1c0cd54

Browse files
coadofacebook-github-bot
authored andcommitted
Export NewAppScreen from the root
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 1c0cd54

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
@@ -132,6 +132,9 @@ module.exports = {
132132
get VirtualizedSectionList() {
133133
return require('./Libraries/Lists/VirtualizedSectionList').default;
134134
},
135+
get NewAppScreen() {
136+
return require('./Libraries/NewAppScreen');
137+
},
135138
// #endregion
136139
// #region APIs
137140
get AccessibilityInfo() {

packages/react-native/index.js.flow

+2
Original file line numberDiff line numberDiff line change
@@ -192,6 +192,8 @@ export type {
192192
} from './Libraries/Lists/VirtualizedSectionList';
193193
export {default as VirtualizedSectionList} from './Libraries/Lists/VirtualizedSectionList';
194194

195+
export * as NewAppScreen from './Libraries/NewAppScreen';
196+
195197
// #endregion
196198
// #region APIs
197199

0 commit comments

Comments
 (0)