Skip to content

Build and read https://loopky.app deck and profile links - #343

Merged
jvsena42 merged 1 commit into
mainfrom
feat/web-links-parse
Sep 25, 2026
Merged

jvsena42 merged 1 commit into
mainfrom
feat/web-links-parse

Conversation

@jvsena42

@jvsena42 jvsena42 commented Sep 25, 2026 •

Copy link
Copy Markdown
Owner

Step 1 of 3. Adds the https form of Loopky's links and teaches the link parser to read it. Nothing emits the new links yet.

  • Deck.webUrl → https://loopky.app/deck/?author={pubky}&id={deckId}
  • PubkyLinks.profileWebUrl → https://loopky.app/profile/?pubky={pubky}
  • PubkyLinks.parse accepts both, including the forms a browser or chat leaves behind: www., no trailing slash, reordered params, #fragment, UTM params, a link inside a sentence. The web form is stricter than pubky://: the account must be a real key.
  • decodeUriComponent sits next to the existing encoder.

Why query params, not a path: the site is static GitHub Pages, where a path route only exists as a 404.html served with status 404.

Landing side: jvsena42/loopky.github.io#1 (the pages, plus assetlinks.json).

Tests: PubkyLinksTest covers round trips, escaped ids, and look-alike hosts such as loopky.app.evil.test and a loopky link nested inside another URL.

🤖 Generated with Claude Code

A pubky:// address is plain text in a pubky.app post and in most chat
clients. Deck.webUrl and PubkyLinks.profileWebUrl build the https form
(/deck/?author=…&id=…, /profile/?pubky=…) the landing site answers, and
PubkyLinks.parse reads it back, so a tapped, pasted or scanned web link
lands on the same screen a pubky:// one does. The web form is stricter:
the account must be a real key, since anyone can hand-edit a URL.

Query parameters rather than path segments because the site is static
GitHub Pages, where a path route only exists as a 404.html.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@jvsena42
jvsena42 added this pull request to stack #346 September 25, 2026 13:10
@jvsena42 jvsena42 changed the title feat(links): build and read https://loopky.app deck and profile links Build and read https://loopky.app deck and profile links Sep 25, 2026
@jvsena42
jvsena42 merged commit b02ebd2 into main Sep 25, 2026
8 checks passed
@jvsena42
jvsena42 deleted the feat/web-links-parse branch September 25, 2026 13:16
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.

1 participant