
과정과는 별개지만 RN에 도움을 받을 수 있을까 싶어서 질문 남깁니다.
현재 Expo에서 권장하는 AuthSession Package에서 Expo Client에서는 구글 로그인이 잘 동작하지만
Android로 배포 후에는 구글 로그인 인증이 {"type": "dismiss"}가 뜨는 현상이 생겼습니다.
해당 이슈는 아직 Expo에서도 제대로 해결하지 못하고 있는 걸로 확인 되었는데,
혹시 Expo에서 Google Login OAuth를 진행해보신 적이 있으실까요?
작성한 코드 및 에러 메세지
const [request, response, promptAsync] = Google.useAuthRequest({
expoClientId: GoogleClientId,
iosClientId: GoogleClientId,
androidClientId: GoogleAndroidClientId,
shouldAutoExchangeCode: false,
clientSecret: GoogleClientSecret,
selectAccount: true,
});
useEffect(() => {
async function login() {
if (response?.type === 'success') {
};
}
login();
}, [response]);
return (
<TouchableOpacity
disabled={!request} title="Login"
onPress={() => {
promptAsync({ showInRecents: true });
}}
>
<View style={styles.googleLoginBox}>
<Image source={require("../../assets/google_logo.png")} style={styles.googleLogoImage}></Image>
<Text style={styles.googleLoginBoxText}>구글 계정으로 로그인하기</Text>
</View>
</TouchableOpacity >
)
결과 (에러 메세지)
{"type": "dismiss"}
