Skip to content

AudienceRenderer

reference
1 min readUpdated

Kind: Class

Source: atloria-monorepo/packages/core/src/rendering/audience-renderer.ts

Audience Renderer

Evaluates audience logic and filters content based on viewer permissions.

Methods

MethodSignatureReturns
renderrender(ast: DocumentAST)string

Where it refuses work

  • AudienceRenderer stops the work with an early return when !matches.
  • AudienceRenderer stops the work with an early return when this.options.viewerAudiences.includes(audienceSlug).
  • AudienceRenderer stops the work with an early return when node.defaultVariant.
  • AudienceRenderer stops the work with an early return when !this.options.expandIncludes.

Was this page helpful?

Download as PDF