This is my code in typescript
function loginWithPassword(user: Object | string, password: string, callback?: Function): void;
I did not know what's happening on this code in typescript
this is the signature definition of function loginWithPassword.
Let's break down this code:
function loginWithPassword(
user: Object | string,
password: string,
callback?: Function): void;
defining that
loginWithPasswordis afunctionwhich will returnvoid
It will acceptthree parameters:
1st paramuserwill be of typeobject or a string
2nd parampasswordwill always be astring
3rd paramcallbackwill be afunction