AppPlugins: Expose react-router to apps (#33775)

* Allow Route component usage in app plugins

* i tried

* fix catalog app

* fix catalog app

* remove catalog changes from this PR

* remove extra files

* feat(plugins): expose react-router to plugins rather than export via grafana-ui

* Bring back query and pathname to AppRootPage and add deprecation notice

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
This commit is contained in:
Dominik Prokop
2021-05-19 19:10:21 +02:00
committed by GitHub
parent fb9223ab42
commit 4cbffae1b4
7 changed files with 28 additions and 8 deletions

View File

@@ -149,6 +149,7 @@ export function getAppRoutes(): RouteDescriptor[] {
},
{
path: '/a/:pluginId/',
exact: false,
// Someday * and will get a ReactRouter under that path!
component: SafeDynamicImport(
() => import(/* webpackChunkName: "AppRootPage" */ 'app/features/plugins/AppRootPage')