If you want to use Vite to build the React Okta App, you maybe face some incompatible issues. I will share some of my research in this post.
Issue 1: Uncaught TypeError: Class extends value undefined is not a constructor or null
As the Okta's staff said, It's a known issue with the ESM bundle of okta-auth-js.
So, we should add the below into the
Issue2: Security.tsx:99 Uncaught ReferenceError: process is not defined
Solution: Add the below code to the
You can find the final version code on okta-demo.