mapquest - MapQuest Route 不适用于欧洲的某些地点
问题描述
我有以下代码在 MapQuest 地图上绘制路线:
this.map = L.mapquest.map('map', {
center: [48.3552767, -99.9995795],
layers: L.mapquest.tileLayer('dark'),
zoom: 2,
zoomAnimation: false,
});
const directions = L.mapquest.directions();
directions.route({
// these are not wokring
// start: [47.372219,8.541973],
// end: [52.18988,21.63049]
// these are working
start: [50.86766, 2.84919],
end: [47.993594, 0.107319]
}, (err, response) => {
this.buildRouteLayers(layers, routeLayer, response, length);
});
我观察到,我只面临包括瑞士和波兰在内的路线的任何纬度/经度对都运行良好的问题。
以下是浏览器控制台上的错误:
Uncaught (in promise) 没有返回任何条件。此路线没有交通数据。
解决方案
原点 47.372219,8.541973 位于河流中。从可通航的道路开始这条路线有点太远了。
推荐阅读
- python - Keras CNN 与 Convolution2D 不兼容
- kubernetes - NGINX 入口 auth-url 返回 404 但端点存在
- python-2.7 - 使用最后两列作为分区将 spark 数据帧转换为 pyspark 中的 hive 分区创建表
- javascript - 如何使用 puppeteer 单击 HTML 选项卡项/过滤器?
- javascript - JavaScript:测试输入参数是否为数组;如果是,则将数组合并为一个大数组
- apache-spark - Spark Dataframe - 每天随机采样记录
- mysql-error-1064 - mariadb 10.3.15 中出现 1064 错误,但 mysql 版本 5.5.62 上没有
- asp.net - 如何处理 Catch 块中的错误
- javascript - 如何在 nativescript vue 中使用 $navigateTo()?
- c# - 以编程方式在 Frame 中插入 XAML