[openstreetmap/openstreetmap-website] Viewing a changeset loses context of previous changeset list (#647)
Andy Allan
notifications at github.com
Wed Nov 9 12:42:51 UTC 2022
> Do you want a bigger rewrite?
So long as it's implemented as a series of smaller PRs :stuck_out_tongue_winking_eye:
This is probably not the best place to expand the discussion, but yes I want us to move away from our building-html-in-javascript approach. It has grown organically and for different reasons, but there's too much `$("<div>").append` style manual assembling of html. These chunks of html could be better built server-side, which is the basis of much of the "hotwire" approach. But it would be a large project to achieve this, and there's a few pre-requisites that need to be completed first e.g. #2364.
> Currently the pagination works with these requests
> https://www.openstreetmap.org/user/(username)/history?list=1&max_id=(id)
> returning a limited amount of changesets starting from the specified id. It's possible to add full pages with urls like this, for example
> https://www.openstreetmap.org/user/(username)/history?max_id=(id)
> then have "Load more" to link to them. Is it going to be "pagination working properly without javascript"?
>From what I understand, then yes. Basically if pagination works with javascript turned off (i.e. with working links and full page reloads) and then with javascript enabled, it can do the enhanced behaviour e.g. incremental loading (like now) and with the url changing to a working permalink (instead of trying to save state in cookies or local storage etc).
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/issues/647#issuecomment-1308694592
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/issues/647/1308694592 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20221109/67c1e2f4/attachment.htm>
More information about the rails-dev
mailing list