// 发起请求,获取图例
var getLayersLegendInfoParams = new L.supermap.GetLayersLegendInfoParameters({
// bbox 或 layers 参数必须至少设置一个参数
// bbox: "114.59,37.76,119.51,42.31",
layers: "show:" + layers,
width: 18,
height: 18
})
官网示例代码,在本地运行显示
Uncaught TypeError: L.supermap.GetLayersLegendInfoParameters is not a constructor
include-leaflet.js和include-web.js都引了