I am trying to reset the styles when I the mouse out event is triggered. But it is giving a error. this is working perfectly fine when I am using react-leaflet 2.8.0. But dont know why its causing an issue now.
geoJsonRef.current.leafletElement.resetStyle(e.target);