123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- ---
- id: options-api
- title: Options Commands
- sidebar_label: Options commands
- ---
-
- ## `setDefaultOptions`
-
- Set default options for all screens. Useful for declaring a consistent style across the app.
-
- #### Parameters
-
- | Name | Type | Required | Description |
- | ------- | ----------------------- | -------- | ------------ |
- | options | [Options](options-root.mdx) | Yes | Options root |
-
- #### Example
-
- ```js
- Navigation.setDefaultOptions({
- bottomTab: {
- textColor: "black",
- selectedTextColor: "blue"
- }
- });
- ```
-
- ## `mergeOptions`
-
- Change navigation options of a component.
-
- #### Parameters
-
- | Name | Type | Required | Description |
- | ----------- | ----------------------- | -------- | ---------------- |
- | componentId | string | Yes | The component id |
- | options | [Options](options-root.mdx) | Yes | Options root |
-
- #### Example
-
- ```js
- Navigation.mergeOptions('componentId', {
- bottomTabs: {
- visible: false
- }
- });
- ```
|