Closed ArthurLobopro closed 6 months ago
We (the maintainers of webextension-polyfill) are not responsible for this type definition. You should contact the source of your type and request a fix there.
Ok
I have the same issue. I managed to track this down. It's already fixed in the source repo: https://github.com/Lusito/webextension-polyfill-ts/blob/2687ea2b007c7a99e0eb19f3790c688ed845f8c3/out/namespaces/runtime.d.ts#L586
However it's still the old version in the repo where the definitions are packaged: https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/webextension-polyfill/namespaces/runtime.d.ts#L452
There is a PR open to merge the fix: https://github.com/DefinitelyTyped/DefinitelyTyped/pull/69704
So we gotta wait for this to be merged. I tried augmenting the type locally but wasn't able to make it work, so just added // @ts-ignore
for now
I am migrating a chrome extension to webextension but this snippet of my code gives me a error saying 0 arguments are expected.
And the typing of sendResponse shows:
Please, can someone correct this type?