mirror of
https://github.com/tauri-apps/plugins-workspace.git
synced 2026-09-04 20:16:34 +02:00
feat(window-state): support using a custom filename (#1138)
* feat(window-state): support using a custom filename ref: https://github.com/tauri-apps/plugins-workspace/pull/1079 * generate api * fmt
This commit is contained in:
@@ -38,5 +38,11 @@ async function restoreState(
|
||||
async function restoreStateCurrent(flags: StateFlags): Promise<void> {
|
||||
return restoreState(getCurrent().label, flags);
|
||||
}
|
||||
/**
|
||||
* Get the name of the file used to store window state.
|
||||
*/
|
||||
async function filename(): Promise<string> {
|
||||
return invoke("plugin:window-state|filename");
|
||||
}
|
||||
|
||||
export { restoreState, restoreStateCurrent, saveWindowState };
|
||||
export { restoreState, restoreStateCurrent, saveWindowState, filename };
|
||||
|
||||
Reference in New Issue
Block a user