0.0.5 • Published 1 year ago

capacitor-plugin-device-settings-permission v0.0.5

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

capacitor-plugin-device-settings-permission

DeviceSettingsPermission is a Capacitor plugin designed to streamline the process of requesting permissions and accessing device settings. It provides a unified API to request and check permissions across different platforms, and offers a simple way to direct users to their device's settings page. This plugin is intended to enhance user experience by making permission management more efficient and user-friendly.

Install

npm install capacitor-plugin-device-settings-permission
npx cap sync

API

requestNotificationPermission()

requestNotificationPermission() => Promise<{ permission: NotificationPermissions; }>

Request permission to show notifications.

Returns: Promise<{ permission: NotificationPermissions; }>

Since: 1.0.0


getNotificationPermission()

getNotificationPermission() => Promise<{ permission: NotificationPermissions; }>

Check the current notification permission status.

Returns: Promise<{ permission: NotificationPermissions; }>

Since: 1.0.0


openAppSettings(...)

openAppSettings(type: AppSettingsType) => Promise<void>

Open the app settings for the app.

ParamTypeDescription
typeAppSettingsTypeThe type of settings to open.

Since: 1.0.0


Enums

NotificationPermissions

MembersValue
GRANTED'granted'
DENIED'denied'

AppSettingsType

MembersValue
NOTIFICATION'notification'
LOCATION'location'
TRACING'tracing'
GENERAL'general'
0.0.5

1 year ago

0.0.4

1 year ago

0.0.3

1 year ago

0.0.2

1 year ago

0.0.1

1 year ago