const Navigator = createStackNavigator({
Search: {
screen: withTheme(SearchScreen),
},
SearchResults: {
screen: withTheme(SearchResultsScreen),
},
SelectedItem: {
screen: withTheme(SelectedItemScreen),
},
}, {
initialRouteName: 'Search',
headerBackTitleVisible: false,
defaultNavigationOptions : { header: null },
})
我知道这是由于withtheme这是我的特别情况。但是我还需要使用临时文件夹包装所有屏幕。那么我怎么可以用hoc