Skip to content

Fix/library loader - #681

Closed
DonovanDeSmedt wants to merge 4 commits into
GoogleMapReact:masterfrom
DonovanDeSmedt:fix/library_loader
Closed

DonovanDeSmedt wants to merge 4 commits into
GoogleMapReact:masterfrom
DonovanDeSmedt:fix/library_loader

Conversation

@DonovanDeSmedt

@DonovanDeSmedt DonovanDeSmedt commented Nov 21, 2018 •

Copy link
Copy Markdown
Contributor

Possible fix for issue 673:

Supports both the previous and current way of loading libraries:

Previous way:

<GoogleMapReact
          bootstrapURLKeys={{
            libraries: 'drawing',
            key: googleMapKey,
          }}
          yesIWantToUseGoogleMapApiInternals
          onGoogleApiLoaded={({ maps }) => {
            console.log(maps.drawing);
          }}
        />

Current way:

<GoogleMapReact
          bootstrapURLKeys={{
            key: googleMapKey,
          }}
          drawingLibrary
          yesIWantToUseGoogleMapApiInternals
          onGoogleApiLoaded={({ maps }) => {
            console.log(maps.drawing);
          }}
        />

When prop updateHeatmap is set to true --> map will rerender.
- New render of <GoogleMapReact> and data is changed, prop updateHeatmap should be true
- New render of <GoogleMapReact> and data is not changed, prop updateHeatmap should be false
* 'master' of github.com:google-map-react/google-map-react:
  Bump to 1.1.1 (GoogleMapReact#680)
  Revert "Added feature: update heat map on data change + fix linting" (GoogleMapReact#679)
  Bump version to 1.1.0 (GoogleMapReact#671)
  Added feature: update heat map on data change + fix linting (GoogleMapReact#593)
  Pass map instance to onDrag handler (GoogleMapReact#656)
  add math abs to avoid negative values when calculating zoom (GoogleMapReact#655)
  Bump version to 1.0.9 (GoogleMapReact#651)
  Custom div style options (GoogleMapReact#634)
  Bump version to 1.0.8 (GoogleMapReact#646)
  Revert 643 fix/map context (GoogleMapReact#645)
  Bump version to 1.0.7 (GoogleMapReact#644)
  Add passive scroll (GoogleMapReact#631)
  Use React 16 portal to render map overlay (GoogleMapReact#643)
  Fix old examples links and add one to new examples (GoogleMapReact#633)
  Bump version to 1.0.6 (GoogleMapReact#621)
  Add prop `onTilesLoaded` (GoogleMapReact#615)
  Fix typo, and call fromContainerPixelToLatLng() as you would expect. (GoogleMapReact#620)
  Update API.md (GoogleMapReact#611)
  Upgrade version to 1.0.5 (GoogleMapReact#607)
  Remove marker jiggle. (GoogleMapReact#603)
@itsmichaeldiego

Copy link
Copy Markdown
Member

@DonovanDeSmedt Great work, thank you so much!

I would keep only the old way, both ways make it more confusing and will lead into conflicts.

Also keep in mind I had to revert your previous PR because builds were failing for some people

@DonovanDeSmedt

Copy link
Copy Markdown
Contributor Author

Ok, I'll remove this one and create a new one for some of the changes of the previous PR.

@DonovanDeSmedt
DonovanDeSmedt deleted the fix/library_loader branch November 26, 2018 19:01
@itsmichaeldiego

Copy link
Copy Markdown
Member

Awesome @DonovanDeSmedt thank you so much!

@lock

lock Bot commented Dec 1, 2019

Copy link
Copy Markdown

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock Bot locked as resolved and limited conversation to collaborators Dec 1, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants