mirror of
https://github.com/google-map-react/google-map-react.git
synced 2025-12-08 18:26:32 +00:00
Skip falsy markers (#204)
This commit is contained in:
parent
6227e4ea35
commit
ef1689e7a3
@ -229,6 +229,7 @@ export default class GoogleMapMarkers extends Component {
|
||||
this.dimesionsCache_ = {};
|
||||
|
||||
const markers = React.Children.map(this.state.children, (child, childIndex) => {
|
||||
if (!child) return undefined;
|
||||
if (child.props.latLng === undefined &&
|
||||
child.props.lat === undefined &&
|
||||
child.props.lng === undefined) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user