首页 / 浏览问题 / WebGIS / 问题详情
 new L.supermap.GraphicLayer(graphics).addTo(map);绘制高效率点图层时报错
4EXP 2025年04月21日
new L.supermap.GraphicLayer(graphics).addTo(map);绘制高效率点图层时报错

iclient-leaflet-es6.min.js:1619  Uncaught TypeError: this._renderer.drawGraphics is not a function
    at i._updatePath (iclient-leaflet-es6.min.js:1619:3796)
    at i._update (iclient-leaflet-es6.min.js:1619:3709)
    at i._reset (Path.js:140:8)
    at i.onAdd (Path.js:85:8)
    at i.onAdd (iclient-leaflet-es6.min.js:1619:610)
    at i._layerAdd (Layer.js:114:8)
    at i.whenReady (Map.js:1465:13)
    at i.addLayer (Layer.js:176:8)
    at i.addTo (Layer.js:52:7)
    at addGraphicLayer

这里

_updatePath: function() {
                let e = this._getGraphicsInBounds();
                this._renderer.drawGraphics(e, this.defaultStyle)
            },
...