Skip to content

Instantly share code, notes, and snippets.

@anhtuank7c
Created May 31, 2017 11:26
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anhtuank7c/fce824aeffdd1b18a71276188917f437 to your computer and use it in GitHub Desktop.
Save anhtuank7c/fce824aeffdd1b18a71276188917f437 to your computer and use it in GitHub Desktop.
Cài đặt react-native-maps
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.0'
target 'demo' do
# Fixes required for pod specs to work with rn 0.42
react_native_path = "../node_modules/react-native"
pod "Yoga", :path => "#{react_native_path}/ReactCommon/yoga"
pod "React", :path => react_native_path
pod 'GoogleMaps' # <~~ remove this line if you do not want to support GoogleMaps on iOS
end
@anhtuank7c
Copy link
Author

Edit AppDelegate.m

@import GoogleMaps;

  [GMSServices provideAPIKey:@"YOUR_KEY"];

@anhtuank7c
Copy link
Author

Go to Google Console dashboard then create a project,
Press enable Google Maps SDK for iOS, then create a key

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment