StasDoskalenko/react-native-google-fit

Expo config plugin

Opened this issue · 2 comments

I'd like to be able to use this with Expo's Managed Workflow and EAS. Would it be possible to create a custom Expo plugin similar to React Native Health?

Hi, I can't get it to work with expo either.

Hey! No Expo plugin is needed to get this library to work. You do still have to create a custom dev client, though.

Try out these steps:

  1. expo install expo-dev-client react-native-google-fit
  2. eas build --profile development --platform android - allow it to create an Expo project on your account, this is what you'll need to obtain the SHA1 from the credentials page
  3. After the build finishes, obtain the SHA1 for your Google OAuth Client ID by visiting https://expo.dev/accounts/[account]/projects/[project]/credentials
    • Press the application identifier
    • Grab value from SHA-1 Certificate Fingerprint
    • Paste in Google Console
  4. yarn expo start --dev-client to start metro
  5. Install the dev client on your device
  6. Edit your app to call on the GoogleFit APIs and watch auth success and subsequent calls work!