#How can I replace "appWindow" from v1?

2 messages · Page 1 of 1 (latest)

daring forge
#

I'm currently migrating to v2 from v1, I have the following line on the frontend: "import { appWindow } from '@tauri-apps/api/window';".
I'm importing because I need to call the function "appWindow.onCloseRequested()".
Now it seems like there's no appWindow exported by @tauri-apps/api/window.
So my question is, how can I use appWindow again.

proven vine
#

Instead of appWindow, use getCurrentWindow for the v2