$ show l4rm4nd/VoucherVault
VoucherVault is a self-hosted Django web application for digitally managing vouchers, gift cards, coupons, and loyalty cards. It provides a full CRUD interface with features like barcode/QR code scanning, expiry notifications via Apprise, multi-currency support via Fixer.io, offline-first capabilities (service worker + IndexedDB sync), OIDC authentication, item sharing between users, and a PWA manifest for mobile installation. The architecture is a monolithic Django app with Celery for background tasks (expiry checks), Redis as a message broker, and optional PostgreSQL or SQLite databases. The frontend uses the NiceAdmin Bootstrap template with custom dark mode and charting via ECharts. The codebase is well-organized with clear separation of concerns (models, views, forms, templates, static assets) and includes internationalization for English, German, French, and Italian. While the application is feature-rich and actively maintained, it lacks automated tests and has some code duplication in templates, which limits its quality score.
The LLM identified 4 files worth highlighting for reuse:
A self-contained offline synchronization manager that uses IndexedDB to queue create/update/delete operations when the network is unavailable. It implements a sync queue with conflict resolution, periodic retry, and integration with the service worker. This pattern is reusable for any web application needing offline-first data persistence with eventual consistency.
A service worker implementing cache-first strategies for static assets and network-first for API calls, with manual cache management (add/remove/purge) exposed via postMessage. It includes versioning, stale-while-revalidate for pages, and an offline fallback page. This is a well-structured, reusable pattern for adding PWA offline support to any Django or similar web app.
A Cloudflare Worker that acts as a secure deep-link importer for VoucherVault. It uses URL hash fragments to pass voucher data without exposing it to the server, then redirects to the app. This is a clean, stateless pattern for building secure sharing links that can be extracted and adapted for other self-hosted applications.
A client-side barcode scanner that uses the ZXing library to decode QR codes and barcodes from camera input or uploaded images. It includes a crop interface for manual selection and fallback to file upload. This component is self-contained and can be reused in any web application requiring barcode scanning without server-side processing.