sergiodxa / remix-auth

Simple Authentication for Remix
MIT License
1.94k stars 112 forks source link

Improve authenticate overload return type #235

Closed aaronadamsCA closed 1 year ago

aaronadamsCA commented 1 year ago

@typescript-eslint/await-thenable doesn't like the new overload signature from #211. When I upgrade remix-auth to v3.5.0, it tells me to remove await from this line:

await authenticator.authenticate("auth0", request, { successRedirect });
Unexpected `await` of a non-Promise (non-"Thenable") value  @typescript-eslint/await-thenable

If authenticate() implementations are expected to be async, then they will always return promises, so Promise<never> would be the correct return type. Just a minor dev experience fix.

arempe93 commented 1 year ago

@sergiodxa is it possible to get a patch release for this? I'm also running into this issue

sergiodxa commented 1 year ago

Published as v3.5.1