alex8088 / quick-start

An easy way to start a front-end project.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Question: type of Window.api

mdruuu opened this issue · comments

Clear and concise description of the problem

Hi,

I am wondering why the api type is set as 'unknown' vs electron being ElectronAPI?

import { ElectronAPI } from '@electron-toolkit/preload'

declare global {
interface Window {
electron: ElectronAPI
api: unknown
}
}

Thank you

Used Scaffolding

create-electron

Suggested solution

n/a

Alternative

No response

Additional context

No response

Validations

You can define specific types according to your own module.