Interface: HasRoleProps
Defined in: packages/sveltekit/src/props.ts:37
Props of <HasRole>. Conditions are ANDed; without any condition nothing passes (deny by default).
svelte
<HasRole role="admin|editor">...</HasRole>
<HasRole allOf={['writer', 'editor']}>...</HasRole>Properties
| Property | Type | Description | Defined in |
|---|---|---|---|
allOf? | NameList | Passes with ALL of these roles. | packages/sveltekit/src/props.ts:43 |
anyOf? | NameList | Passes with ANY of these roles. | packages/sveltekit/src/props.ts:41 |
children? | Snippet<[]> | - | packages/sveltekit/src/props.ts:46 |
fallback? | Snippet<[]> | Rendered when the check fails. | packages/sveltekit/src/props.ts:48 |
not? | boolean | Invert the check (render children when the user does NOT have the roles). | packages/sveltekit/src/props.ts:45 |
role? | NameList | The role, or ANY of the roles ('writer|editor' or a list). | packages/sveltekit/src/props.ts:39 |
