xxxxxxxxxx
// The error "No overload matches this call" occurs when we call a function and pass it a
// parameter that doesn't match any of its specified overloads.
// To solve the error, make sure the function is being called with the correct number of
// arguments of the correct type
// Consider following function
const myFunction = (a: string, b: string, c?: string) => {
}
// No overload matches this call - not enough required parameters
myFunction("Hello");
// OK because third parameter is optional
myFunction("Hello", "World");
// No overload matches this call - too many parameters
myFunction("Hello", "World", "And", "Again");
// No overload matches this call - mismatched types.
// This last overload gave the following error.
// Argument of type 'number' is not assignable to parameter of type 'string'
myFunction("Hello", 2);
xxxxxxxxxx
You've likely tried to pass the wrong number of arguments to a function, or used the incorrect type for an argument(s)
Ensure that you're using the function you're calling correctly. Try refer to developer documentation or see a tutorial for more specific help.