diff --git a/x-pack/plugins/cloud_security_posture/public/plugin.tsx b/x-pack/plugins/cloud_security_posture/public/plugin.tsx index 9114dcd9e2f4d..a941f1f770b13 100755 --- a/x-pack/plugins/cloud_security_posture/public/plugin.tsx +++ b/x-pack/plugins/cloud_security_posture/public/plugin.tsx @@ -67,19 +67,21 @@ export class CspPlugin Component: LazyCspCustomAssets, }); + // Keep as constant to prevent remounts https://github.com/elastic/kibana/issues/146773 + const App = (props: CspRouterProps) => ( + + +
+ + + +
+
+
+ ); + return { - getCloudSecurityPostureRouter: () => (props: CspRouterProps) => - ( - - -
- - - -
-
-
- ), + getCloudSecurityPostureRouter: () => App, }; }