Код: Выделить всё
npx react-native bundle \
--entry-file index.ts \
--platform ios \
--dev false \
--bundle-output ios/main.jsbundle \
--assets-dest ios
Код: Выделить всё
import "expo-router/entry";
< /code>
Теперь, когда я пытаюсь запустить сборку выпуска, мое приложение все еще остается застрявшим на экране Splash. Если я заменю это < /p>
// import { AppRegistry } from "react-native";
// import Index from "./app";
// AppRegistry.registerComponent("TwinX", () => Index);
< /code>
, где индекс - это просто белый экран с центрированным текстом, он работает нормально, но когда я заменяю индекс точкой входа для экранов выставки, он не работает. В настоящее время с моим index.ts я вижу эти ошибки в xcode < /p>
Running ""
Invariant Violation: "" has not been registered. This can happen if:
* Metro (the local dev server) is run from the wrong folder. Check if Metro is running, stop it and restart it in the current project.
* A module failed to load due to an error and `AppRegistry.registerComponent` wasn't called.
Unhandled JS Exception: Invariant Violation: "" has not been registered. This can happen if:
* Metro (the local dev server) is run from the wrong folder. Check if Metro is running, stop it and restart it in the current project.
* A module failed to load due to an error and `AppRegistry.registerComponent` wasn't called.
libc++abi: terminating due to uncaught exception of type facebook::jsi::JSError: Exception in HostFunction: Unhandled JS Exception: Invariant Violation: "" has not been registered. This can happen if:
* Metro (the local dev server) is run from the wrong folder. Check if Metro is run..., stack:
anonymous@35:290
runApplication@157:1517
Error: Exception in HostFunction: Unhandled JS Exception: Invariant Violation: "" has not been registered. This can happen if:
* Metro (the local dev server) is run from the wrong folder. Check if Metro is run..., stack:
anonymous@35:290
runApplication@157:1517
< /code>
Если я добавлю эту строку в appdelegate.mm,
self.moduleName = @"appName";Я пытался исправить его в течение последних двух дней, любая помощь будет высоко оценена.
Подробнее здесь: https://stackoverflow.com/questions/795 ... ntry-point
Мобильная версия