refreshNavigationItem() for Lightning Experience
Refreshes the selected navigation object’s home page. Typically, standard and custom objects open the object’s list view. If split view is open, it’s refreshed. This method works only in Lightning console apps.
This method refreshes in the background. If the list view has unsaved changes, the method returns false and doesn’t refresh the navigation item. The method doesn’t set focus on the navigation tab.
The following navigation items aren’t supported:
- Custom Visualforce tabs
- Custom Aura component tabs
- Custom web tabs
- Dashboards
- Reports
None
This example reloads the current navigation item’s home page, such as an object’s list view, or its split view.
This Aura component has a button that, when pressed, refreshes the navigation item.
Component code:
Controller code:
This method returns a promise that, upon success, resolves to true. The promise is rejected on error.