plugins: remove unnecessary use of convertLegacyRouteRef(s)

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
This commit is contained in:
Patrik Oldsberg
2025-11-23 14:17:58 +01:00
parent c8fc1429b4
commit 1c7ea4a3e8
33 changed files with 170 additions and 182 deletions
+1 -5
View File
@@ -15,16 +15,12 @@
*/
import { PageBlueprint } from '@backstage/frontend-plugin-api';
import { convertLegacyRouteRef } from '@backstage/core-compat-api';
import { rootCatalogKubernetesRouteRef } from '../plugin';
export const kubernetesPage = PageBlueprint.make({
params: {
path: '/kubernetes',
// you can reuse the existing routeRef
// by wrapping into the convertLegacyRouteRef.
routeRef: convertLegacyRouteRef(rootCatalogKubernetesRouteRef),
// these inputs usually match the props required by the component.
routeRef: rootCatalogKubernetesRouteRef,
loader: () => import('../Router').then(m => <m.Router />),
},
});
+1 -2
View File
@@ -14,7 +14,6 @@
* limitations under the License.
*/
import { convertLegacyRouteRefs } from '@backstage/core-compat-api';
import { createFrontendPlugin } from '@backstage/frontend-plugin-api';
import { kubernetesPage } from './pages';
import { entityKubernetesContent } from './entityContents';
@@ -37,5 +36,5 @@ export default createFrontendPlugin({
kubernetesAuthProvidersApi,
kubernetesClusterLinkFormatterApi,
],
routes: convertLegacyRouteRefs({ kubernetes: rootCatalogKubernetesRouteRef }),
routes: { kubernetes: rootCatalogKubernetesRouteRef },
});