tractatus/src
TheFlow 6aed0dd275 fix(cache): prevent caching of admin files and API responses
CRITICAL FIX: Automatic cache invalidation for admin JavaScript files.

Root cause: Service worker and browser cache serving stale admin files
even after deploying fixes. Users had to manually clear cache daily.

Changes:
1. Service Worker (v0.1.2):
   - Added NEVER_CACHE_PATHS for /js/admin/, /api/, /admin/
   - These paths now ALWAYS fetch from network, never cache
   - Bumped version to trigger cache clear on all clients

2. Server-side Cache Control:
   - Added Cache-Control: no-store headers for admin/API paths
   - Added Pragma: no-cache and Expires: 0 for belt-and-suspenders
   - Prevents browser AND proxy caching

This ensures:
- Admin JavaScript updates deploy immediately
- API responses are never stale
- No more manual cache clearing required

Testing:
- Admin files will now always be fresh from server
- Service worker will auto-update to v0.1.2 on next visit
- Browsers will respect no-cache headers going forward

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-24 18:34:06 +13:00
..
config fix(submissions): restructure Economist package and fix article display 2025-10-24 08:47:42 +13:00
controllers feat(crm): complete Phase 3 multi-project CRM + critical bug fixes 2025-10-24 18:10:14 +13:00
middleware fix(cache): prevent caching of admin files and API responses 2025-10-24 18:34:06 +13:00
models feat(crm): complete Phase 3 multi-project CRM + critical bug fixes 2025-10-24 18:10:14 +13:00
routes feat(crm): complete Phase 3 multi-project CRM + critical bug fixes 2025-10-24 18:10:14 +13:00
services feat(translation): implement DeepL translation service (SOVEREIGN) 2025-10-24 11:16:33 +13:00
utils fix(submissions): restructure Economist package and fix article display 2025-10-24 08:47:42 +13:00
server.js fix(submissions): restructure Economist package and fix article display 2025-10-24 08:47:42 +13:00