Skip to content

Commit

Permalink
test: ✅ use correct import syntax for general scenarios
Browse files Browse the repository at this point in the history
  • Loading branch information
gingerbenw committed Mar 18, 2024
1 parent b896b3e commit 5161e2f
Showing 1 changed file with 8 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,15 @@ async function loadReactNavigationScenario (scenario) {
if (typeof scenario.registerScreens === 'function') {
scenario.registerScreens()
} else {
const Navigation = await import('react-native-navigation')
Navigation.registerComponent('Scenario', () => scenario.App)
Navigation.setRoot({
root: {
component: {
name: 'Scenario'
import('react-native-navigation').then(({ Navigation }) => {
Navigation.registerComponent('Scenario', () => scenario.App)
Navigation.setRoot({
root: {
component: {
name: 'Scenario'
}
}
}
})
})
}
}
Expand Down

0 comments on commit 5161e2f

Please sign in to comment.