react-native-ui-lib
react-native-ui-lib copied to clipboard
[White screen issue] Cannot evaluate the playground demo
Description
The playround demo shows white blank screen
Related to
- [ X] Components
- [X ] Demo
- [ ] Docs
- [ ] Typings
Steps to reproduce
- Clone the sourcebase
- npm install
- npm run build:dev
- npm run build
- npm run android
Expected behavior
The playground demo should work smoothly for sourcebase evaluation purpose
Actual behavior
The playground demo shows white blank screen
More Info
Code snippet
BUNDLE ./index.js
WARN `new NativeEventEmitter()` was called with a non-null argument without the required `addListener` method.
WARN `new NativeEventEmitter()` was called with a non-null argument without the required `removeListeners` method.
ERROR Invariant Violation: ViewPropTypes has been removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'., js engine: hermes
WARN [TypeError: Cannot read property 'default' of undefined]
ERROR Error: Requiring module "src\screens\MainScreen.js", which threw an exception: Invariant Violation: ViewPropTypes has been removed from React Native. Migrate to ViewPropTypes exported from 'deprecated-react-native-prop-types'., js engine: hermes
ERROR TypeError: Cannot read property 'isBatchingLegacy' of undefined, js engine: hermes
WARN Possible Unhandled Promise Rejection (id: 0):
TypeError: Cannot read property 'default' of undefined
TypeError: Cannot read property 'default' of undefined
at anonymous (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:273781:60)
at wrap (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:271325:65)
at NavigationComponent (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:271935:63)
at staticOptionsIfPossible (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:272968:71)
at applyStaticOptions (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:272961:57)
at component (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:272946:32)
at crawl (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:272903:32)
at map (native)
at stack (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:272934:83)
at crawl (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:272901:28)
at setRoot (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:273017:34)
at setRoot (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:270578:37)
at setRoot (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:270146:47)
at startApp (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:269690:81)
at getDefaultScreenAndStartApp$ (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:269713:21)
at call (native)
at tryCatch (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:25010:23)
at anonymous (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:24990:34)
at anonymous (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:25041:30)
at call (native)
at tryCatch (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:25010:23)
at invoke (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:25048:30)
at anonymous (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:25054:19)
at tryCallOne (/root/react-native/ReactAndroid/hermes-engine/.cxx/Release/535v146a/x86/lib/InternalBytecode/InternalBytecode.js:53:16)
at anonymous (/root/react-native/ReactAndroid/hermes-engine/.cxx/Release/535v146a/x86/lib/InternalBytecode/InternalBytecode.js:139:27)
at apply (native)
at anonymous (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:30757:26)
at _callTimer (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:30657:17)
at _callReactNativeMicrotasksPass (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:30692:17)
at callReactNativeMicrotasks (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:30900:44)
at __callReactNativeMicrotasks (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:3361:46)
at anonymous (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:3139:45)
at __guard (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:3344:15)
at flushedQueue (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:3138:21)
at invokeCallbackAndReturnFlushedQueue (http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false&app=com.mupendo.uisampling&modulesOnly=false&runModule=true:3131:33)
Screenshots/Video

Environment
react: ^17.0.2 => 17.0.2
react-native: 0.69.3 => 0.69.3
react-native-ui-lib: 6.19.0
node: 16.13.2
Affected platforms
- [ X] Android
- [ X] iOS
- [ ] Web
ERROR TypeError: Cannot read property 'isBatchingLegacy' of undefined, js engine: hermes
ERROR TypeError: Cannot read property 'isBatchingLegacy' of undefined, js engine: hermes
ERROR TypeError: Cannot read property 'isBatchingLegacy' of undefined, js engine: hermes
ERROR TypeError: Cannot read property 'isBatchingLegacy' of undefined, js engine: hermes
ERROR TypeError: Cannot read property 'isBatchingLegacy' of undefined, js engine: hermes
ERROR TypeError: Cannot read property 'isBatchingLegacy' of undefined, js engine: hermes
ERROR TypeError: Cannot read property 'isBatchingLegacy' of undefined, js engine: hermes
ERROR TypeError: Cannot read property 'isBatchingLegacy' of undefined, js engine: hermes
We get the same issue and above relevant logs
ERROR Warning: React.createElement: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.
Check your code at MainScreen.js:164.
in MainScreen (at gestureHandlerRootHOC.tsx:13)
in RNGestureHandlerRootView (at GestureHandlerRootView.android.tsx:23)
in GestureHandlerRootView (at gestureHandlerRootHOC.tsx:12)
in gestureHandlerRootHOC(MainScreen) (created by WrappedComponent)
in WrappedComponent (at renderApplication.js:50)
in RCTView (at View.js:32)
in View (at AppContainer.js:92)
in RCTView (at View.js:32)
in View (at AppContainer.js:119)
in AppContainer (at renderApplication.js:43)
in unicorn.MainScreen(RootComponent) (at renderApplication.js:60)
ERROR Error: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.
Check the render method of `MainScreen`.
This error is located at:
in RCTView (at View.js:32)
in View (at view/index.js:85)
in View (at MainScreen.js:270)
in MainScreen (at gestureHandlerRootHOC.tsx:13)
in RNGestureHandlerRootView (at GestureHandlerRootView.android.tsx:23)
in GestureHandlerRootView (at gestureHandlerRootHOC.tsx:12)
in gestureHandlerRootHOC(MainScreen) (created by WrappedComponent)
in WrappedComponent (at renderApplication.js:50)
in RCTView (at View.js:32)
in View (at AppContainer.js:92)
in RCTView (at View.js:32)
in View (at AppContainer.js:119)
in AppContainer (at renderApplication.js:43)
in unicorn.MainScreen(RootComponent) (at renderApplication.js:60), js engine: hermes
ERROR Error: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.
Check the render method of `MainScreen`.
This error is located at:
in RCTView (at View.js:32)
in View (at view/index.js:85)
in View (at MainScreen.js:270)
in MainScreen (at gestureHandlerRootHOC.tsx:13)
in RNGestureHandlerRootView (at GestureHandlerRootView.android.tsx:23)
in GestureHandlerRootView (at gestureHandlerRootHOC.tsx:12)
in gestureHandlerRootHOC(MainScreen) (created by WrappedComponent)
in WrappedComponent (at renderApplication.js:50)
in RCTView (at View.js:32)
in View (at AppContainer.js:92)
in RCTView (at View.js:32)
in View (at AppContainer.js:119)
in AppContainer (at renderApplication.js:43)
in unicorn.MainScreen(RootComponent) (at renderApplication.js:60), js engine: hermes
fyi