TS: typedef for toReceiveMessage is wrong
See original GitHub issueThe toReceiveMessage
matcher is async
, but the exported signature is not.
Thus TS complains:

Should be defined as an async matcher.
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Typescript prefers sources to compiled typedefs #47369
This causes an error at main.ts:1:14 : Type 'null' is not assignable to type 'string'. Loose nulls are permitted in node_modules/ ...
Read more >How to typedef a function according to tslint with "() => void"?
As typescript tell you, you need to define precisely the prototype of the function you want to use. You will gain auto-completion and...
Read more >typedef | typescript-eslint
typedef. Require type annotations in certain places. TypeScript cannot always infer types for all places in code. Some locations require type annotations ...
Read more >767538 – Compilation error when defining the same type ...
The duplicate typedefs are invalid in both ISO C89 and C99, it is only valid in the upcoming C1X standard that is being...
Read more >Two ways you can take advantage of types in JavaScript ...
This blog post describes how you can enable javascript intellisense and design time error highlighting without TypeScript.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Not sure, but I do know that VSCode uses TypeScript, so at some level it’s a TS warning. Looks like this warning in particular was added with this PR: https://github.com/microsoft/TypeScript/pull/32384
I’ll give the new version a try in a bit and report back.
@neezer It should now be fixed in v1.5.1 - let me know if you have any other issues!