The app loads without any problem. However, when I press on the Go to About Screen, I get an error:
Can't find variable: Router
But, if I don't import Router and just code in this way this.props.navigator.push('about'); it works fine.
Also please keep in mind that all these components (ExNavigationDemo, HomeScreen, AboutScreen) are in separate files. So, if place all these components in the same file (index.android.js), then its working fine. But I want to keep them in separate files. What am I missing here?
I am using ExNavigation in my react-native App. I have a very simple app, where ExNavigationDemo is the main app.
index.android.js:
HomeScreen.js:
AboutScreen.js:
The app loads without any problem. However, when I press on the Go to About Screen, I get an error:
But, if I don't import Router and just code in this way
this.props.navigator.push('about');
it works fine.Also please keep in mind that all these components (ExNavigationDemo, HomeScreen, AboutScreen) are in separate files. So, if place all these components in the same file (index.android.js), then its working fine. But I want to keep them in separate files. What am I missing here?