Skip to content

UsePlacementOptions

UsePlacementOptions = object

Options for the usePlacement hook.

optional autoLoad?: boolean

Automatically load a decision on mount. Default true.


optional autoTrackImpression?: boolean

Whether a visible decision auto-tracks a resolution-time impression. Default true. Set false to suppress it — e.g. when you attach UsePlacementResult.exposureRef and want the impression to fire on viewport exposure instead (plan 144 TASK-9 / REQ-15). Read at mount.


optional contextMode?: RevTurbineContextMode

Context resolution mode. Default 'auto'.


optional overrides?: RevTurbinePlacementDecisionOverrides

Override segment, plan, or usage for testing.


optional placement?: RevTurbinePlacementConfig

Placement configuration (name, scope key, metadata).


optional placementExposure?: PlacementExposureMode

When the presentation-writing impression fires (plan 144 TASK-11 / REQ-17). legacy_resolution (default) fires at resolution as today; render at render; viewport on viewport exposure (falling back to resolution when IntersectionObserver is unavailable). Only viewport moves the dashboard denominator — attach UsePlacementResult.exposureRef to the visual root to use it. Read at mount.


optional surfaceSlot?: RevTurbineSurfaceSlotConfig

Canonical surface slot configuration (preferred over placement).


optional traits?: Record<string, string | number | boolean>

Custom traits to include in the decision request.


optional ttlMs?: number

Decision cache TTL in milliseconds.


optional userId?: string

Target user ID. Falls back to the SDK’s current user context.