add guest js api + command to permission list

pull/2421/head
VulnX 5 months ago
parent 7b6fde0697
commit ff160a2909
No known key found for this signature in database
GPG Key ID: CC61EA8583C4CD8E

File diff suppressed because one or more lines are too long

@ -1347,6 +1347,13 @@ async function size(path: string | URL): Promise<number> {
})
}
/**
* Get the file name from a file path (desktop) or content URI (android)
*/
async function fileName(filepath: string | URL): Promise<string> {
return await invoke('plugin:fs|file_name', {filepath});
}
export type {
CreateOptions,
OpenOptions,
@ -1395,5 +1402,6 @@ export {
exists,
watch,
watchImmediate,
size
size,
fileName
}

@ -14,4 +14,5 @@ commands.allow = [
"read_text_file_lines_next",
"exists",
"scope-app-recursive",
"file_name",
]

Loading…
Cancel
Save