AppPermissions
Provides access to application-level system permission APIs.
import { app } from '@mobrowser/api';
const status = app.permissions.getStatus('camera')
Methods
getStatus()
getStatus(name: PermissionName): PermissionStatus;
Returns the current permission status without showing any system prompt.
Available on macOS and Windows.
request()
request(name: PermissionName): Promise<PermissionStatus>;
Requests the specified permission from the system. On macOS, may show a system prompt.
Available on macOS. On other platforms, resolves to 'unsupported'.
openSystemSettings()
openSystemSettings(name: PermissionName): void;
Opens the relevant System Settings pane for the permission.
Available on macOS and Windows.