From bad46b25e1d70ca446b3f996f94bcb915b1e7da4 Mon Sep 17 00:00:00 2001 From: Patrik Oldsberg Date: Thu, 12 Oct 2023 14:29:17 +0200 Subject: [PATCH] core-plugin-api: added docs for convertLegacyRouteRef and note that it's temporary Signed-off-by: Patrik Oldsberg --- .../src/routing/convertLegacyRouteRef.ts | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/packages/core-plugin-api/src/routing/convertLegacyRouteRef.ts b/packages/core-plugin-api/src/routing/convertLegacyRouteRef.ts index 2b84440108..9778625355 100644 --- a/packages/core-plugin-api/src/routing/convertLegacyRouteRef.ts +++ b/packages/core-plugin-api/src/routing/convertLegacyRouteRef.ts @@ -40,12 +40,38 @@ import { toInternalSubRouteRef } from '../../../frontend-plugin-api/src/routing/ // eslint-disable-next-line @backstage/no-relative-monorepo-imports import { toInternalExternalRouteRef } from '../../../frontend-plugin-api/src/routing/ExternalRouteRef'; +/** + * A temporary helper to convert a legacy route ref to the new system. + * + * @public + * @remarks + * + * In the future the legacy createRouteRef will instead create refs compatible with both systems. + */ export function convertLegacyRouteRef( ref: LegacyRouteRef, ): RouteRef; + +/** + * A temporary helper to convert a legacy sub route ref to the new system. + * + * @public + * @remarks + * + * In the future the legacy createSubRouteRef will instead create refs compatible with both systems. + */ export function convertLegacyRouteRef( ref: LegacySubRouteRef, ): SubRouteRef; + +/** + * A temporary helper to convert a legacy external route ref to the new system. + * + * @public + * @remarks + * + * In the future the legacy createExternalRouteRef will instead create refs compatible with both systems. + */ export function convertLegacyRouteRef< TParams extends AnyRouteParams, TOptional extends boolean,