-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(api): permission types for mobile plugins #10799
Conversation
let's have a central place to keep the permission types ref tauri-apps/plugins-workspace#979
Package Changes Through 7ec6ffdThere are 8 changes which include @tauri-apps/api with prerelease, tauri with prerelease, tauri-utils with prerelease, tauri-cli with prerelease, @tauri-apps/cli with prerelease, tauri-codegen with prerelease, tauri-bundler with prerelease, tauri-build with prerelease Planned Package VersionsThe following package releases are the planned based on the context of changes in this pull request.
Add another change file through the GitHub UI by following this link. Read about change files or the docs at github.com/jbolda/covector |
tooling/api/src/core.ts
Outdated
* This should be used by plugin authors to wrap their actual implementation. | ||
*/ | ||
async function checkPermissions<T>(plugin: string): Promise<T> { | ||
return invoke(`plugin:${plugin}|check_permissions`) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
won't this require an implementation in Rust? if so, then I'd prefer to keep them in the same place as the rust impl, not here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these are abstract methods..
the API here is only meant to be used by plugin authors (e.g. FS, NFC, notification plugin) to share the proper types
open fun checkPermissions(invoke: Invoke) { |
@objc open func checkPermissions(_ invoke: Invoke) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see, this fine then
let's have a central place to keep the permission types
ref tauri-apps/plugins-workspace#979