diff --git a/lib/GoogleMap.js b/lib/GoogleMap.js index 2b20633b..ff1f2108 100644 --- a/lib/GoogleMap.js +++ b/lib/GoogleMap.js @@ -160,10 +160,12 @@ var GoogleMap = (function (_Component) { // // In this state, the DOM of google.maps.Map is already initialized in // my innerHTML. Adding extra React components will not clean it - // in current (0.13.3) version. It will use prepend to add DOM of + // in current version*. It will use prepend to add DOM of // GoogleMapHolder and become a sibling of the DOM of google.maps.Map // Not sure this is subject to change // + // *current version: 0.13.3, 0.14.2 + // _react2["default"].createElement( _creatorsGoogleMapHolder2["default"], _extends({ map: this.state.map }, mapProps), diff --git a/lib/Marker.js b/lib/Marker.js index 4d018477..862cd40d 100644 --- a/lib/Marker.js +++ b/lib/Marker.js @@ -137,9 +137,8 @@ var Marker = (function (_Component) { return; } - var _props = this.props; - var anchorHolderRef = _props.anchorHolderRef; - var marker = _props.marker; + var anchorHolderRef = this.props.anchorHolderRef; + var marker = this.state.marker; if (anchorHolderRef) { if ("MarkerClusterer" === anchorHolderRef.getAnchorType()) { diff --git a/src/Marker.js b/src/Marker.js index 205bece7..c6025abf 100644 --- a/src/Marker.js +++ b/src/Marker.js @@ -77,7 +77,9 @@ export default class Marker extends Component { return; } - const {anchorHolderRef, marker} = this.props; + const {anchorHolderRef} = this.props; + const {marker} = this.state; + if (anchorHolderRef) { if ("MarkerClusterer" === anchorHolderRef.getAnchorType()) {