Auth0 Home Blog Docs

Type 'Bluebird<string>' is not assignable to type 'Promise<string>' error when using Typescript



This applies to the Auth0 Javascript SDK v2.13.0 on a Node 10.5.0

I just switched to Typescript (v3.1.6) and am converting a JS file over. I’m using the auth0 SDK and I installed the latest @types/auth0.

When trying to compile my code, I get the following error:

Type 'Bluebird<string>' is not assignable to type 'Promise<string>'.
  Property '[Symbol.toStringTag]' is missing in type 'Bluebird<string>'.

Looking at the Types file, I can see that it imports Promise from bluebird… but I’m not using bluebird, I’m using the native Promise class.

So, how do I do this? Do I need to take and modify the Types file myself?