software-mansion-labs / expo-maps

81 stars 3 forks source link

AppDelegateSubscriber / Config Plugins #32

Open EvanBacon opened 2 years ago

EvanBacon commented 2 years ago

To auto configure react-native-maps in expo prebuild we use some dangerous mods. It'd be a bit better to implement the ReactDelegate: example.

This could setup Google Maps automatically ([GMSServices provideAPIKey:apiKey];) in the applicationDidLaunch method, with this system it would be standard to read the API key from the Info.plist which would be injected via config plugins.

Alternatively, the whole 'provide API key' could just be exposed via JS and invoked before the app renders any Google Maps, I'm not familiar enough with API to say if this works.

Anyways, great job on the library so far! Really excited to see a new maps library.

szdziedzic commented 2 years ago

Thank you so much! This is something we definitely want to do.