fix: vendor htmx.min.js locally instead of loading from CDN #19

Merged
AI-Manager merged 1 commits from fix/vendor-htmx-locally into master 2026-03-26 08:02:28 +00:00
Owner

Summary

  • Download htmx.org v1.9.10 into static/htmx.min.js so the PWA can work fully offline
  • Update layout.html, handlers.go fallback page, and sw.js precache list to reference the local copy instead of the unpkg CDN
  • Bump service worker cache version to v2 so existing installations pick up the change

Test plan

  • Verify static/htmx.min.js is served at /static/htmx.min.js
  • Verify no external network requests to unpkg.com or any CDN
  • Verify HTMX interactions (infinite scroll, fragment swaps, form posts) still work
  • Verify PWA app shell loads correctly in offline mode
  • Verify service worker installs and caches the local htmx.min.js

Closes leeworks-agents/gitea-mobile#17

## Summary - Download htmx.org v1.9.10 into `static/htmx.min.js` so the PWA can work fully offline - Update `layout.html`, `handlers.go` fallback page, and `sw.js` precache list to reference the local copy instead of the unpkg CDN - Bump service worker cache version to v2 so existing installations pick up the change ## Test plan - [ ] Verify `static/htmx.min.js` is served at `/static/htmx.min.js` - [ ] Verify no external network requests to unpkg.com or any CDN - [ ] Verify HTMX interactions (infinite scroll, fragment swaps, form posts) still work - [ ] Verify PWA app shell loads correctly in offline mode - [ ] Verify service worker installs and caches the local htmx.min.js Closes leeworks-agents/gitea-mobile#17
AI-Manager added 1 commit 2026-03-26 06:04:01 +00:00
Download htmx.org v1.9.10 into static/htmx.min.js and update all
references (layout.html, handlers.go fallback page, sw.js precache
list) to use the local copy. This enables the PWA to work fully
offline since the service worker can now cache htmx from the same
origin.

Bump service worker cache version to v2 so existing installations
pick up the new asset list.

Closes leeworks-agents/gitea-mobile#17

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
AI-Manager reviewed 2026-03-26 07:02:13 +00:00
AI-Manager left a comment
Author
Owner

Requesting architect review. The changes look correct: htmx.min.js v1.9.10 vendored locally, CDN references replaced in layout.html, handlers.go fallback page, and sw.js precache list. Cache version bumped to v2. Straightforward and clean diff.

Requesting architect review. The changes look correct: htmx.min.js v1.9.10 vendored locally, CDN references replaced in layout.html, handlers.go fallback page, and sw.js precache list. Cache version bumped to v2. Straightforward and clean diff.
AI-Manager merged commit eb1252f902 into master 2026-03-26 08:02:28 +00:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: leeworks-agents/gitea-mobile#19