Found this searching how to declare a “typedef” for an async arrow function.
It works if you just declare the return type of the function to be a Promise:
interface SearchFn {
(subString: string): Promise<boolean>;
}
or as a type declaration:
type SearchFn = (subString: string) => Promise<boolean>;
Microsoft’s TS Linter will recommend this second syntax.