DevSettings
The DevSettings module exposes methods for customizing settings for developers in development.
Reference
Methodsβ
addMenuItem()β
tsx
staticaddMenuItem(title:string,handler:()=>any);
Add a custom menu item to the Dev Menu.
Parameters:
| Name | Type |
|---|---|
| title Required | string |
| handler Required | function |
Example:
tsx
DevSettings.addMenuItem('Show Secret Dev Screen',()=>{
Alert.alert('Showing secret dev screen!');
});
reload()β
tsx
staticreload(reason?:string):void;
Reload the application. Can be invoked directly or on user interaction.
Example:
tsx
<Buttontitle="Reload"onPress={()=>DevSettings.reload()}/>