feat: Add on mode init hook (#3882)

This commit is contained in:
Igor Octaviano authored and GitHub committed 2024-01-08 14:12:26 -05:00
1 parent 5a1cb842f0
commit f58725ce40
2 files changed
+19

No files matched your search

@@ -9,9 +9,18 @@ sidebar_label: Lifecycle Hooks
Currently, there are two hooks that are called for modes:
- onModeInit
- onModeEnter
- onModeExit
## onModeInit
This hook gets run before the defined route has been entered by the mode. This
hook can be used for initialization before the first render.
This is called before `onModeEnter` calls. This allows modes to add or activate their own
data sources and configuration before entering the mode (pre registrations).
## onModeEnter
This hook gets run after the defined route has been entered by the mode. This