未找到 HTTP 404 资源 - Grafana 世界地图插件自定义标记

HTTP 404 Resource not found - Grafana World Map Plugin Custom Marker

我正在尝试使用 Leaflet JS 库将自定义标记与 Grafana 世界地图插件结合使用。但即使在我将自定义标记图像放入源目录后,我仍然收到以下错误 -

http://localhost:3000/datacenter.png 404 (Not Found)

我的代码是这样的-

var dataCenterIcon = window.L.icon({
    iconUrl: 'datacenter.png',
    iconSize:     [38, 95], // size of the icon
    iconAnchor:   [22, 94], // point of the icon which will correspond to marker's location
    popupAnchor:  [-3, -76] // point from which the popup should open relative to the iconAnchor
});

window.L.marker([caponeDCLat, caponeDCLong], {icon: dataCenterIcon}).addTo(this.map);

任何人都可以提供一些关于我在这里可能做错了什么的意见。

由于是Grafana插件,所以路径都是相对于Grafana主页的。

以下是 WorldPing 应用程序中的示例:

<img src="public/plugins/raintank-worldping-app/img/loading-pulse.svg"

参见:

https://github.com/raintank/worldping-app/blob/master/dist/components/probe/partials/probe_list.html#L11