Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fatal exception loaders #3

Open
Lelelo1 opened this issue Feb 28, 2021 · 2 comments
Open

Fatal exception loaders #3

Lelelo1 opened this issue Feb 28, 2021 · 2 comments

Comments

@Lelelo1
Copy link

Lelelo1 commented Feb 28, 2021

***** Fatal JavaScript exception - application has been terminated. *****
NativeScript encountered a fatal error: Uncaught Error: Module parse failed: Unexpected token (13:7)
File was processed with these loaders:
*../node_modules/@nativescript/webpack/hmr/hot-loader.js
You may need an additional loader to handle the result of these loaders.
| 'use strict';
|
import typeof AccessibilityInfo from './Libraries/Components/AccessibilityInfo/AccessibilityInfo';
| import typeof ActivityIndicator from './Libraries/Components/ActivityIndicator/ActivityIndicator';
| import typeof Button from './Libraries/Components/Button';
at
../../../node_modules/react-native/index.js(file:///app/vendor.js:67201:7)
at webpack_require(file: src/webpack/bootstrap:74:0)
at ./components/UIScreen.tsx(file: src/components/UIScreen.tsx:1:0)
at webpack_require(file: src/webpack/bootstrap:74:0)
at ./components/Navigator.tsx(file: src/components/Navigator.tsx:1:0)
at webpack_require(file: src/webpack/bootstrap:74:0)
at (file: src/app.ts:1:31)
at ./app.ts(file:///app/bundle.js:113:30)
at __webpack_requir<…>
(CoreFoundation) *** Terminating app due to uncaught exception 'NativeScript encountered a fatal error: Uncaught Error: Module parse failed: Unexpected token (13:7)
File was processed with these loaders:
*../node_modules/@nativescript/webpack/hmr/hot-loader.js
You may need an additional loader to handle the result of these loaders.
| 'use strict';
|
import typeof AccessibilityInfo from './Libraries/Components/AccessibilityInfo/AccessibilityInfo';
| import typeof ActivityIndicator from './Libraries/Components/ActivityIndicator/ActivityIndicator';
| import typeof Button from './Libraries/Components/Button';
at
../../../node_modules/react-native/index.js(file:///app/vendor.js:67201:7)
at webpack_require(file: src/webpack/bootstrap:74:0)
at ./components/UIScreen.tsx(file: src/components/UIScreen.tsx:1:0)
at webpack_require(file: src/webpack/bootstrap:74:0)
at ./components/Navigator.tsx(file: src/components/Navigator.tsx:1:0)
at webpack_require(file: src/webpack/bootstrap:74:0)
at (file: src/app.ts:1:31)
at ./app.ts(fil<…>

Occurs when importing and using anything from rn, on the master branch.

@Lelelo1
Copy link
Author

Lelelo1 commented Feb 28, 2021

On the haul branch with the following code app.ts (like on master):

import * as React from 'react';

/* Controls react-nativescript log verbosity. true: all logs; false: only error logs. */
Object.defineProperty(global, '__DEV__', { value: false });

/*
In NativeScript, the app.ts file is the entry point to your application.
You can use this file to perform app-level initialization, but the primary
purpose of the file is to pass control to the app’s first module.
*/

import * as ReactNativeScript from 'react-nativescript';
import { mainStackNavigator as AppContainer } from './components/Navigator';

ReactNativeScript.start(React.createElement(AppContainer, {}, null));

/*
Do not place any code after the application has been started as it will not
be executed on iOS.
*/

--> Uncaught TypeError: ReactReconciler is not a function

@shirakaba
Copy link
Member

As I mentioned here: #2 (comment)

I don’t know how to use React NativeScript and React Native at the same time; it always throws that ReactReconciler is not a function error. I’ve given up on mixing RNS and RN, and have changed focus to using RN in a vanilla NativeScript app (as on the haul branch). And on that front, I’m blocked on RCTBridge exiting the app without giving an error stack.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants