ActionSheet

Cross platform Action sheet, with a support for native iOS solution

PROPS

namedescriptiontypedefault
visibleWhether to show the action sheet or notbool
titleTitle of the action sheet. Note: if both title and message are not passed will not render the title view at allstringundefined
messageMessage of the action sheetstringundefined
cancelButtonIndexIndex of the option represents the cancel action (to be displayed as the separated bottom bold button)number
destructiveButtonIndexIndex of the option represents the destructive action (will display red text. Usually used for 'delete' or 'abort' actions)number
optionsList of options for the action sheet, follows the Button prop types (supply 'label' string and 'onPress' function)arrayOf
onDismisscallback for when dismissing the action sheet, usually used for setting visible prop to falsefunc
useNativeIOSShould use the native action sheet for iOSbool
showCancelButtonWhen passed (only with useNativeIOS), will display a cancel button at the bottom (overrides cancelButtonIndex)boolfalse

LIVE EXAMPLE

CODE SAMPLE

See example here.