Skip to content

Conversation

@Akeboshiwind
Copy link
Collaborator

  • Uses lz-string to compress url params.
  • Backwards compatible using a new uri-version parameter

I tested out both lz-string and fflate.
Using gzip with fflate is way smaller than lz-string in around the same time, but when I tried to url encode the output it 10x the output size 😅.

Copy link
Contributor

@johantonelli johantonelli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm :shipit:

;; 'my.app.thing :trace ;; Some namespaces you might want detailed logging

(defn- decompress-params [{:keys [uri-version] :as query-params}]
(let [decompress (case uri-version
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It could be more intuitive to be an if if there's only one case with a default (I know, I'm a hypocrite)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I left it like this because I’ve changed the uri format enough times to know I’ll change it again 😅

@refset
Copy link
Contributor

refset commented Oct 26, 2025

Hey @Akeboshiwind what was your main objective with this? Want to make sure it's added for the right reasons

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants