I’m implementing Auth0 in a React TypeScript site and am trying to get the https://auth0.com/docs/quickstart/spa/react to work.
Specifically, when the react-auth0-wrapper.js is converted to react-auth0-wrapper.tsx I get TS errors on the following lines.
const loginWithPopup = async () => {
const handleRedirectCallback = async () => {
An async function or method in ES5/ES3 requires the Promise constructor. Make sure you have a declaration for the Promise constructor or include ES2015 in your --lib option.
The lib option of tsconfig.json looks like this
"lib": [
"dom",
"dom.iterable",
"esnext"
],
Any thoughts or insights appreciated.