leptos_use

Function use_permission

Source
pub fn use_permission(permission_name: &str) -> Signal<PermissionState>
Expand description

Reactive Permissions API.

§Demo

Link to Demo

§Usage

let microphone_access = use_permission("microphone");

§Server-Side Rendering

On the server the returned signal will always be PermissionState::Unknown.