clerk / clerk-expo-starter

Expo starter project using Clerk for authentication
93 stars 21 forks source link

`signUp.create` fails with error ===`undefined` #7

Closed pixelpax closed 1 year ago

pixelpax commented 1 year ago

I didn't even know that undefined was throwable. But using the default app here, it is.

signUp is bytecode, and therefore impossible for me to debug.

Does not give me faith that clerk is a good choice for our project. I was about as bullish as someone can be after seeing the t3 video-- I'm not sure why y'all would spend the effort to market your react-native solution and leave it DOA 😬

perkinsjr commented 1 year ago

Hi @pixelpax

I can't recreate this, from the starter.

Our RN is very much actively developed on with many users using it in production. You can find guides to integrating yourself here: https://beta-docs.clerk.com/quickstarts/expo

This Expo starter was just updated today with new SDK features that make it easier to authenticate users, especially if you are using OAuth which is faster and better then the Expo integrations.

Happy help debug but need more details.

  1. What are you settings Clerk (email, passwords, OAuth)
  2. How did you create the error.

You can access the errors for example:

try {
      await signUp.create({
        emailAddress,
        password,
      });

      // send the email.
      await signUp.prepareEmailAddressVerification({ strategy: "email_code" });

      // change the UI to our pending section.
      setPendingVerification(true);
    } catch (err: any) {
     ///contains errors
      console.error(JSON.stringify(err, null, 2));
    }