You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The @types/chrome type library seems to be more comprehensive.
I agree, there are few types missing from chrome-types in addition to the above - chrome.runtime.lastError also isn't available as well, however @types/chrome works well.
The current issue I have with @types/chrome is the lack of Promise overflows. It always types extension v3 calls as synchronous with callback even if I prepend an await or add a .then().catch(). In the end I decided to use chrome-types and just provide my own global types for the enums I want to reference.
https://developer.chrome.com/docs/extensions/reference/api/runtime#example-uninstall-url
TypeScript gives error:
Property 'OnInstalledReason' does not exist on type 'typeof runtime'.ts(2339)
The text was updated successfully, but these errors were encountered: