Yuhyeon0516 / ReactNative-Instagram-Clone-ExpoCLI

0 stars 0 forks source link

Do GoogleSignin receive idToken is null in android #2

Closed Yuhyeon0516 closed 1 year ago

Yuhyeon0516 commented 1 year ago

When proceeding with "GoogleSignin" in Android, IdToken is null and login is not possible.

Yuhyeon0516 commented 1 year ago

There were several complex problems.

  1. GoogleSignin.configure() -> GoogleSignin.configure({WEB_CLIENT_ID}) WEB_CLIENT_ID exist in google-services.json image

  2. debug keystore setting with use "expo credentials:manager"

image image image image

image

  1. run adb uninstall com.instagram
  2. run npx android prebuild & npm run android
Yuhyeon0516 commented 1 year ago

if used react native cli, need creating keystore

  1. run below command sudo keytool -genkey -v -keystore debug.keystore -alias debug -keyalg RSA -keysize 2048 -validity 10000

  2. created keystore move to ./android/app/

  3. replace signingConfigs in ./android/app/build.gradle

    • Before
      signingConfigs {
      debug {
          storeFile file('debug.keystore')
          storePassword 'android'
          keyAlias 'androiddebugkey'
          keyPassword 'android'
      }
      }