turbo clerk auth not working

Just cloned repo from official clerk-turbo template.

My app runs just fine, untill I try to log in.

I've changes oauth strategy to google, and it works.. kinda. It loads the browser, lets me provide all google credentials, lets me submit, but does not login. Just nothing. No errors, nothing.

all I did was change strategy to google, my signInWithOauth looks like:
import { useOAuth } from "@clerk/clerk-expo";
import React from "react";
import { Button, View } from "react-native";
import { useWarmUpBrowser } from "../hooks/useWarmUpBrowser";

const SignInWithOAuth = () => {
  useWarmUpBrowser();

  const { startOAuthFlow } = useOAuth({ strategy: "oauth_google" });

  const handleSignInWithGoogle = React.useCallback(async () => {
    try {
      const { createdSessionId, signIn, signUp, setActive } =
        await startOAuthFlow();
      if (createdSessionId) {
        setActive({ session: createdSessionId });
      } else {
        // Modify this code to use signIn or signUp to set this missing requirements you set in your dashboard.
        console.log(signIn);
        console.log(signUp);

        throw new Error(
          "There are unmet requirements, modifiy this else to handle them",
        );
      }
    } catch (err) {
      console.log(JSON.stringify(err, null, 2));
      console.log("error signing in", err);
    }
  }, []);

  return (
    <View className="rounded-lg border-2 border-gray-500 p-4">
      <Button title="Sign in with Google" onPress={handleSignInWithGoogle} />
    </View>
  );
};

export default SignInWithOAuth;


Also I've noticed that SetActive, SignIn and SignUp are of type any. Should it be that way?
Was this page helpful?