From 565071f25850391b0acb2d3d686f0b0996969c2c Mon Sep 17 00:00:00 2001 From: Alex Rybchenko Date: Fri, 22 Jul 2022 11:02:06 +0200 Subject: [PATCH] updated changeset Signed-off-by: Alex Rybchenko --- .changeset/violet-trees-play.md | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.changeset/violet-trees-play.md b/.changeset/violet-trees-play.md index c56635633c..00f1e156a8 100644 --- a/.changeset/violet-trees-play.md +++ b/.changeset/violet-trees-play.md @@ -2,4 +2,13 @@ '@backstage/plugin-shortcuts': minor --- -Fixed shortcuts initialization when using firestore +Internal observable replaced with a mapping from the storage API. This fixes shortcuts initialization when using firestore. + +`ShortcutApi.get` method, that returns an immediate snapshot of shortcuts, made public. + +Example of how to get and observe `shortcuts`: + +```typescript +const shortcutApi = useApi(shortcutsApiRef); +const shortcuts = useObservable(shortcutApi.shortcut$(), shortcutApi.get()); +```