Troubleshooting
The ReactNativeToast TurboModule cannot be found
A common error is TurboModuleRegistry.getEnforcing(...): 'ReactNativeToast' could not be found. Verify that:
- React Native is 0.76 or newer
- The New Architecture is enabled
- The native app was rebuilt after installation
- CocoaPods was reinstalled on iOS
- The app is not running inside Expo Go
Restarting Metro cannot add a new native module to an installed binary.
Android cannot resolve the Toaster dependency
If Gradle cannot find com.github.getActivity:Toaster:13.8, add JitPack to the app's settings.gradle or settings.gradle.kts:
dependencyResolutionManagement {
repositories {
google()
mavenCentral()
maven { url = uri("https://jitpack.io") }
}
}Corporate repository proxies must also allow access to https://jitpack.io.
iOS compilation or linking fails
Clean and reinstall Pods:
cd ios
rm -rf Pods Podfile.lock
pod install --repo-updateThen build the .xcworkspace. Ensure that the Podfile does not disable React Native Codegen and that the deployment target satisfies the current React Native release.
A toast does not appear during startup
When the Activity or UIWindow is not ready, the native layer keeps the latest request briefly and retries. For long initialization sequences, show the toast after the first screen mounts instead of calling it at module scope.
Position differs between platforms
- Top and bottom positions account for safe areas
- A zero
yOffsetapplies default safe spacing - Android uses dp and iOS uses points
Native.setGravityis an Android compatibility API; regular calls should useposition
Eight-digit colors have the wrong opacity
The package accepts #AARRGGBB, not the web-oriented #RRGGBBAA. For example, an 80% opaque black is #CC000000.
Import succeeds in Expo but calls fail
The app is usually running an old development client or Expo Go. Run expo prebuild and create a new client. An OTA update cannot introduce a new native dependency.