#⨯ ReferenceError: window is not defined

4 messages · Page 1 of 1 (latest)

fresh cradle
#

Hi i get some error i cant fix please help me thank you
⨯ ReferenceError: window is not defined
at file:///C:/Users/Sinan/Desktop/NextApp/node_modules/@tauri-apps/api/chunk-O3VGRXBA.js:1:11157
at ModuleJob.run (node:internal/modules/esm/module_job:194:25) {
page: '/'
}

random parcel
#

It should work if you change this import: ts import { invoke } from "@tauri-apps/api"; to this ```ts
import { invoke } from "@tauri-apps/api/tauri";

#

ah no, the shell import also triggers it. Try changing it to import the inner items instead of the whole module so for example ```ts
import { Command } from "@tauri-apps/api/shell";