ToastModule

class ToastModule(reactContext: ReactApplicationContext) : NativeToastAndroidSpec

NativeModule that allows JS to show an Android Toast.

Constructors

Link copied to clipboard
constructor(reactContext: ReactApplicationContext)

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
open override fun canOverrideExistingModule(): Boolean

Return true if you intend to override some other native module that was registered e.g. as part of a different package (such as the core one). Trying to override without returning true from this method is considered an error and will throw an exception during initialization. By default all modules return false.

Link copied to clipboard
Link copied to clipboard
open override fun getName(): String
Link copied to clipboard
open override fun getTypedExportedConstants(): Map<String, Any>
Link copied to clipboard
open override fun initialize()

This method is called after ReactApplicationContext has been created.

Link copied to clipboard
open override fun invalidate()

Allow NativeModule to clean up. Called before React Native instance is destroyed.

Link copied to clipboard

Allow NativeModule to clean up. Called before {CatalystInstance#onHostDestroy}

Link copied to clipboard
open override fun show(message: String?, durationDouble: Double)
Link copied to clipboard
open override fun showWithGravity(message: String?, durationDouble: Double, gravityDouble: Double)
Link copied to clipboard
open override fun showWithGravityAndOffset(message: String?, durationDouble: Double, gravityDouble: Double, xOffsetDouble: Double, yOffsetDouble: Double)