Gigi
4cc32c27de
fix(api): detect crawlers and redirect browsers to SPA
...
Browsers get 302 redirect to / where the SPA handles routing client-side with the original /a/{naddr} URL preserved. Crawlers/bots get the full HTML with OG meta tags.
2025-10-16 14:43:29 +02:00
Gigi
99bfe209a5
fix(api): use meta refresh instead of SPA boot in OG endpoint
...
Browsers will immediately redirect to / and load the SPA client-side, while crawlers/bots ignore meta refresh and only see the OG meta tags.
2025-10-16 14:38:17 +02:00
Gigi
0a28bfbd50
fix(api): replace any type with Filter from nostr-tools
2025-10-16 14:32:35 +02:00
Gigi
ba9fb109f6
refactor(api): DRY improvements for article OG endpoint
...
- Extract fetchEventsFromRelays helper to eliminate duplication
- Add setCacheHeaders helper for consistent header setting
- Parallelize article and profile fetching for faster response
- Move relayPool.close() to finally block to prevent leaks
- Remove redundant cacheKey variable and sorting
2025-10-16 14:31:39 +02:00
Gigi
94dc95e1f0
feat(api): dynamic OG HTML for /a/{naddr} using relay metadata
2025-10-16 14:21:49 +02:00