Код: Выделить всё
■ spliceWaypointsに option & bindPopupを 関連付けたい
( want to associate [1] and [2])
★個別追加(Individual Addition)
// https://www.npmjs.com/package/leaflet-routing-machine/v/2.2.4
//start:0,Move:1 /Add:0 /latlng
routeControl.spliceWaypoints(0, 0, [38.2601, 140.8824]); ---------[1]
//↓↓ 同じマーカーを追加しても、二重に重なって希望の結果が得られない
(Adding the same marker results in duplicates and the desired results are not achieved)
L.marker([38.2601, 140.8824], { --------------------------------[2]
icon: startIcon,
draggable: true
}).bindPopup('popupText')
PS
Поскольку вопросы задаются японцами, некоторые вопросы трудно понять.
Подробнее здесь: https://stackoverflow.com/questions/793 ... r-option-b
Мобильная версия