simon-git: puzzles (main): Ben Harris

Commits to Tartarus hosted VCS tartarus-commits at lists.tartarus.org
Fri Oct 21 10:29:14 BST 2022


TL;DR:
  0197ca4 js: Percent-encode game IDs in URLs and decode them again on input

Repository:     https://git.tartarus.org/simon/puzzles.git
On the web:     https://git.tartarus.org/?p=simon/puzzles.git
Branch updated: main
Committer:      Ben Harris <bjh21 at bjh21.me.uk>
Date:           2022-10-21 10:29:14

commit 0197ca43594fbe7cd44377078296720ac7499887
web diff https://git.tartarus.org/?p=simon/puzzles.git;a=commitdiff;h=0197ca43594fbe7cd44377078296720ac7499887;hp=373dadacc06210197e3d68c55a6d611126915120
Author: Ben Harris <bjh21 at bjh21.me.uk>
Date:   Fri Oct 21 09:55:35 2022 +0100

    js: Percent-encode game IDs in URLs and decode them again on input
    
    This is necessary to allow all random seeds to round-trip properly.
    It's probably not currently necessary for descriptive game IDs, but it
    won't hurt.
    
    I've deliberately gone for encoding only those characters that are not
    valid in fragment identifiers to minimise the ugliness of the generated
    URLs.  For slightly interesting historical reasons, '#' is not valid in
    a fragment identifier, so all random seed links end up a little bit
    ugly.

 emcclib.js | 4 ++--
 emccpre.js | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)



More information about the tartarus-commits mailing list