Installation
@remix-run/node or @remix-run/server-runtime.
Setup
1. Create the client instance
2. Ensure identity in the root loader
Request flow
Using createLoader
ThecreateLoader helper auto-extracts identity and context from the Remix request:
Multiple zones
Lower-level helpers
runOptionsFromRequest(request)
Extract identity and context fields manually:
ensureIdentityCookie(request)
Returns a Set-Cookie header string if no identity exists, or null if the visitor already has one:
Handling JSON responses
Click tracking
EveryRunResult includes redirectionUrl and trackClick(). Two patterns:
Compatibility with the client tracker
Adddata-rlvt-ssr="true" to your wrapper element. The client-side tracker automatically skips server-rendered zones.