zcreativelabs / react-simple-maps

Beautiful React SVG maps with d3-geo and topojson using a declarative api.
https://www.react-simple-maps.io/
MIT License
3.04k stars 424 forks source link

"undefined" class in ZoomableGroup #253

Open lucasvazq opened 3 years ago

lucasvazq commented 3 years ago

Description

If you create a ZoomableGroup and don't add the className attribute, it will be created with the following classes: rsm-zoomable-group undefined.

Example

Search undefined in https://www.react-simple-maps.io/docs/zoomable-group/ 2021-03-21_20-50-15

Importance

This can lead to real problems if someone has a class called undefined, something dangerous in js applications by the way, but not that common.

How to temporarily avoid this problem

To avoid this problem, just create a ZoomableGroup and pass an empty string in the className attr.