From 046d2177bc869427dc9c1cd11156a0d733f88e3a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Valentin=20Gr=C3=A9goire?= <32612304+valentingregoire@users.noreply.github.com> Date: Thu, 22 May 2025 18:09:23 +0200 Subject: [PATCH] fix(docs): Fixed the code example for the Permissions - Frontend Integration MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The current default code is exactly what it is in this example, except for the flawed import. Signed-off-by: Valentin Grégoire <32612304+valentingregoire@users.noreply.github.com> --- docs/permissions/frontend-integration.md | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/docs/permissions/frontend-integration.md b/docs/permissions/frontend-integration.md index 1e83f8ad7d..a3949d3606 100644 --- a/docs/permissions/frontend-integration.md +++ b/docs/permissions/frontend-integration.md @@ -13,16 +13,11 @@ However, there are some cases where the integrator needs to supplement the polic If your Backstage permission policy may return a `DENY` for users requesting the `catalogEntityCreatePermission`, it may make sense, for example, to remove access to the `/catalog-import` page entirely: ```tsx title="packages/app/src/App.tsx" -/* highlight-add-start */ import { RequirePermission } from '@backstage/plugin-permission-react'; -import { catalogEntityCreatePermission } from '@backstage/plugin-catalog-common'; -/* highlight-add-end */ +import { catalogEntityCreatePermission } from '@backstage/plugin-catalog-common/alpha'; const routes = ( - {/* highlight-remove-next-line */} - } /> - {/* highlight-add-start */} } /> - {/* highlight-add-end */} {/* ... */} );