2 min readMar 29, 2026by jakub

Trident PRISM

Dynamic rendering reverse proxy for Single Page Applications.

PRISM sits between clients and your SPA origin, renders JavaScript into static HTML using headless Chromium, caches the result, and serves fully rendered pages. Search engines, social crawlers, and (optionally) all users get complete HTML without any changes to your frontend code.

Client --> PRISM --> SPA Origin
             |
        Cache HIT? --> serve rendered HTML
             |
           MISS
             |
        Chrome renders page
             |
        Cache + serve

Why PRISM?

Single Page Applications (React, Vue, Angular, Svelte, Next.js) render content in the browser using JavaScript. Search engines and social crawlers often can't execute JavaScript, so they see an empty page. This hurts SEO, social sharing previews, and AI crawlers indexing your content.

PRISM solves this without changing your code:

  • Zero SPA changes -- works with any React, Vue, Svelte, or Angular app as-is
  • Bot detection -- 70+ crawler patterns (Google, Bing, GPTBot, ClaudeBot, social bots, SEO tools)
  • Render-all mode -- serve rendered HTML to everyone, not just bots
  • In-memory cache -- LRU with configurable max entries, memory limit, TTL, and grace period
  • Request coalescing -- one render per URL at a time, concurrent requests wait for the result
  • Chrome pool -- configurable tab count, automatic tab recycling, crash recovery with backoff
  • Circuit breaker -- stops rendering after consecutive failures, auto-recovers
  • Admin API -- health checks, Prometheus metrics, cache purge, manual render trigger
  • Security -- SSRF protection, egress allowlist, per-domain rate limiting
  • Shadow mode -- render in background and log diffs without serving rendered HTML

How It Works

Bot-Only Mode (default)

PRISM detects search engine crawlers by User-Agent and only renders pages for them. Regular users get the normal SPA response (fast, client-side rendered).

Browser (human)  --> PRISM --> pass through to origin (no rendering)
Googlebot        --> PRISM --> render with Chrome --> serve HTML

Render-All Mode

Every request gets a fully rendered HTML response. Useful for sites where you want server-side rendering without modifying your SPA.

Any client --> PRISM --> render with Chrome --> serve HTML

Response Headers

PRISM adds headers to every response so you can verify it's working:

HeaderValuesDescription
x-prism-renderedtruePage was rendered through Chrome
x-prism-cacheHIT, MISS, STALE, BYPASSCache status
x-prism-render-timemillisecondsHow long the render took

Quick Start

The fastest way to try PRISM:

Bash
# Docker Compose (includes Chromium)
curl -sSL https://raw.githubusercontent.com/Trident-Cache/prism/main/docker-compose.yml -o docker-compose.yml
# Edit ORIGIN in docker-compose.yml to point to your SPA
docker compose up -d

Or install the binary:

Bash
curl -sSfL https://get.trident-cache.com/prism | sh -s -- --with-service

See Installation for detailed instructions.

Was this page helpful?
Trident PRISM — Trident HTTP Cache Proxy | qoliber Docs