terkelg/prompts

Typescript error

Raduc4 opened this issue · 1 comments

Hello, i've faced this error in my project and don't really know how to deal with it.
Type 'string' is not assignable to type 'PromptType | Falsy | PrevCaller<"v", PromptType | Falsy>'.ts(2322)

` await client.start({
phoneNumber: async () => await ask("Please enter your phone number"),
password: async () => await ask("Please enter your password"),
phoneCode: async () => await ask("Please enter the received code"),
onError: (e) => console.log(e)

});`

Could you post the code for your ask function? It looks like you're passing a string instead of a prompts object