- Add self-hosted push notifications using VAPID (no external services) - Create PushSubscription model in database - Implement server-side push logic with web-push library - Add notification helpers for list events (items, invitations, collaborators) - Create NotificationSettings UI component for profile page - Add usePushNotifications React hook for subscription management - Create API routes for subscription management and VAPID key - Update service worker with push event handlers - Integrate notifications into item actions (add, remove, complete) - Integrate notifications into sharing actions (invite, accept, remove) - Add VAPID key generation script - Add comprehensive documentation and setup guides Notifications are sent when: - Items are added/removed/completed in shared lists - Users are invited to lists - Invitations are accepted - Collaborators are removed from lists Works on iOS 16.4+ (when installed to home screen), Android, and desktop browsers.
16 lines
573 B
Plaintext
16 lines
573 B
Plaintext
DATABASE_URL="mysql://user:password@host:port/database"
|
|
|
|
# NextAuth Configuration
|
|
# NEXTAUTH_URL should be your production URL in production
|
|
NEXTAUTH_URL=http://localhost:3000
|
|
|
|
# Generate a secure secret with: openssl rand -base64 32
|
|
NEXTAUTH_SECRET=your-secret-key-here-please-change-in-production
|
|
AUTH_SECRET=your-secret-key-here-please-change-in-production
|
|
|
|
# Web Push Notifications (VAPID)
|
|
# Generate keys with: npm run vapid:generate
|
|
VAPID_PUBLIC_KEY=your-vapid-public-key-here
|
|
VAPID_PRIVATE_KEY=your-vapid-private-key-here
|
|
VAPID_SUBJECT=mailto:your-email@example.com
|