[openstreetmap/openstreetmap-website] Add PWA geo protocol handler (PR #5736)
Anton Khorev
notifications at github.com
Tue Mar 11 10:01:57 UTC 2025
@AntonKhorev commented on this pull request.
> @@ -80,6 +80,11 @@ OSM = {
const hash = OSM.parseHash(location.hash);
+ const geoURI = Object.fromEntries(new URLSearchParams(
+ params.geouri?.replaceAll(/[?;]/g, "&")?.replace(":", "=")
If you don't need `u`, you don't need any regexps.
If you need `u`, that parameter can't have `&` inside and you can have a simpler regexp. But do you need `u`? Are you going to show the uncertainty?
If you want to parse *every* parameter, you'll need a complicated regexp. What do you need other parameters for?
`z` is not a RFC 5870 parameter.
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/5736#discussion_r1988865392
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/pull/5736/review/2673724431 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20250311/6c829eda/attachment.htm>
More information about the rails-dev
mailing list