[RN][iOS][google] Set region only when view has width&height#785
Merged
spikebrehm merged 1 commit intomasterfrom Nov 10, 2016
Merged
[RN][iOS][google] Set region only when view has width&height#785spikebrehm merged 1 commit intomasterfrom
spikebrehm merged 1 commit intomasterfrom
Conversation
- Fix type issue in AIRMapManager - Setup Gemfile in example/ios dir to avoid problems with different versions of cocoapods - Update examples-setup.md to use bundler - Change MapView so that we only set the native region prop when there is a width and height. GoogleMaps iOS requires the width and height to properly calculate the map zoom level.
spikebrehm
approved these changes
Nov 10, 2016
| const { region, initialRegion } = this.props; | ||
| if (region && this.state.isReady) { | ||
| this.map.setNativeProps({ region }); | ||
| } else if (initialRegion && this.state.isReady) { |
There was a problem hiding this comment.
Because of the change to _onLayout()?
Contributor
Author
There was a problem hiding this comment.
For google+ios, this will cause a region calculation that is incorrect. For mapkit+ios it will cause the map to redundantly set the region because it will happen in _onLayout anyway.
| cd ios | ||
| pod install | ||
| bundle install | ||
| bundle exec pod install |
There was a problem hiding this comment.
Do we really need both? Can it just be the second?
Contributor
Author
There was a problem hiding this comment.
@spikebrehm unless there is a way to add a command to run pod install from the Gemfile I think we need both.
Contributor
Author
There was a problem hiding this comment.
oh are you saying that bundle exec runs bundle install automatically? I don't know much about bundler tbh
pinpong
pushed a commit
to pinpong/react-native-maps
that referenced
this pull request
Feb 28, 2025
…fter-layout [RN][iOS][google] Set region only when view has width&height
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
@spikebrehm @lelandrichardson