Filter out templates
Signed-off-by: Bogdan Nechyporenko <bnechyporenko@bol.com>
This commit is contained in:
committed by
blam
parent
0182d61b98
commit
92cf86a4b5
@@ -93,3 +93,18 @@ You can also further customize groups by passing in a `titleComponent` instead
|
||||
of a `title` which will be a component to use as the header instead of just the
|
||||
default `ContentHeader` with the `title` set as it's value.
|
||||

|
||||
|
||||
There is also an option to hide some templates.
|
||||
You can have several use cases for that:
|
||||
|
||||
- it's still in an experimental phase, so you can combine it with feature flagging for example
|
||||
- you don't want to make them accessible from template list, but only open it on some action with pre-filled data.
|
||||
- show different set of templates depends on target environment
|
||||
|
||||
```typescript jsx
|
||||
<ScaffolderPage
|
||||
templateFilter={entity =>
|
||||
entity?.metadata?.tags?.includes('experimental') ?? false
|
||||
}
|
||||
/>
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user