Skip to content

feat(audience): attach identityType to track()/page() events - #2940

Merged
nattb8 merged 1 commit into
mainfrom
feat/audience-persist-identity
Aug 4, 2026
Merged

nattb8 merged 1 commit into
mainfrom
feat/audience-persist-identity

Conversation

@nattb8

@nattb8 nattb8 commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

Summary

userId already carries forward from the last identify() call onto every subsequent track()/page() event; identityType did not. This persists identityType alongside userId on the SDK instance and attaches it to track()/page() the same way, clearing both on reset()/consent downgrade.

Test plan

  • jest (audience/sdk, audience/core) — 461 tests, 0 failed
  • tsc --noEmit — no type errors
  • oxlint (audience package tree) — no new warnings/errors

@github-actions

github-actions Bot commented Aug 3, 2026 •

Copy link
Copy Markdown

✅ Audience Bundle Size — @imtbl/audience

Metric Size Delta vs main (63b3018)
Gzipped 11666 bytes (11.39 KB) +25 bytes
Raw (minified) 32919 bytes +256 bytes

Budget: 24.00 KB gzipped (warn at 20.00 KB)

@nx-cloud

nx-cloud Bot commented Aug 3, 2026 •

Copy link
Copy Markdown

View your CI Pipeline Execution ↗ for commit c51fb54

Command Status Duration Result
nx affected -t build,test ✅ Succeeded 6s View ↗

💡 Verify your cache is correct by running tasks in a sandbox. Read docs ↗


☁️ Nx Cloud last updated this comment at 2026-08-04 00:07:09 UTC

@github-actions

github-actions Bot commented Aug 3, 2026

Copy link
Copy Markdown

✅ Pixel Bundle Size — @imtbl/pixel

Metric Size Delta vs main
Gzipped 6968 bytes (6.80 KB) 0 bytes
Raw (minified) 19325 bytes 0 bytes

Budget: 10.00 KB gzipped (warn at 8.00 KB)

@nattb8 nattb8 changed the title Attach identityType to track()/page() events, matching userId's existing persistence feat(audience): attach identityType to track()/page() events Aug 3, 2026
…e() events

userId already carries forward from the last identify() call onto
subsequent track()/page() events; identityType did not. Mirrors
Segment/PostHog, which persist the last identify()'d identity and
reattach it to later events until the next identify() or a
reset/consent downgrade.
@nattb8
nattb8 force-pushed the feat/audience-persist-identity branch from 1274129 to c51fb54 Compare August 4, 2026 00:06
@nattb8
nattb8 marked this pull request as ready for review August 4, 2026 00:11
@nattb8
nattb8 requested a review from a team as a code owner August 4, 2026 00:11
@nattb8
nattb8 added this pull request to the merge queue Aug 4, 2026
Merged via the queue into main with commit 3a118da Aug 4, 2026
8 checks passed
@nattb8
nattb8 deleted the feat/audience-persist-identity branch August 4, 2026 00:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants