@hlfan commented on this pull request.

It might be worth looking into the Valhalla API if `car` could replace `auto` 
as the `vehicleType`, so we don't need an extra demo params object there.

> @@ -80,11 +80,20 @@
             }
           })
         });
+        const demoQuery = new URLSearchParams({ profile: DEMO_PARAMS[modeId] 
});

```suggestion
        const demoQuery = new URLSearchParams({
          profile: DEMO_PARAMS[modeId],
          wps: points.flatMap(({ lat, lng }) => [lng, lat])
        });
```

> @@ -174,15 +175,23 @@
           // invalidate cache
           cachedHints = [];
         }
-
+        const demoQuery = new URLSearchParams({ srv: DEMO_PARAMS[modeId] });

Could this be done with Array.indexOf?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/6693#pullrequestreview-3651613795
You are receiving this because you are subscribed to this thread.

Message ID: 
<openstreetmap/openstreetmap-website/pull/6693/review/[email protected]>
_______________________________________________
rails-dev mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/rails-dev

Reply via email to