Js Amap Route Planning how to delete the old route?

call Amap"s route planning with AMap.Driving. After each location, the route is re-planned through search, but the old route still exists. I don"t know how to delete it.

//
var driving = new AMap.Driving({
    map: map,
    autoFitView: false
});
// 
driving.search(new AMap.LngLat(lng1, lat1), new AMap.LngLat(lng2, lat2));


Mar.24,2021

// remove
// 
map.remove(marker);
// 
map.remove([marker,circle]);

// clearMap
map.clearMap();
Menu