Skip to content

feat: super properties for posthog-node#2729

Closed
harshit078 wants to merge 2 commits intoPostHog:mainfrom
harshit078:feat/add/super-properties
Closed

feat: super properties for posthog-node#2729
harshit078 wants to merge 2 commits intoPostHog:mainfrom
harshit078:feat/add/super-properties

Conversation

@harshit078
Copy link
Copy Markdown

@harshit078 harshit078 commented Dec 11, 2025

Problem

Changes

  • added registeredProperties in prepareEventMessage
  • this allows prepareEventMessage to ensure that every event includes globally registered super properties.
  • Added tests to verify the correct behavior of property registration and overriding.

Release info Sub-libraries affected

Libraries affected

  • All of them
  • posthog-js (web)
  • posthog-js-lite (web lite)
  • posthog-node
  • posthog-react-native
  • @posthog/react
  • @posthog/ai
  • @posthog/nextjs-config
  • @posthog/nuxt
  • @posthog/rollup-plugin
  • @posthog/webpack-plugin

Checklist

  • Tests for new code
  • Accounted for the impact of any changes across different platforms
  • Accounted for backwards compatibility of any changes (no breaking changes!)
  • Took care not to unnecessarily increase the bundle size

If releasing new changes

  • Ran pnpm changeset to generate a changeset file
  • Added the "release" label to the PR to indicate we're publishing new versions for the affected packages

@vercel
Copy link
Copy Markdown

vercel Bot commented Dec 11, 2025

@harshit078 is attempting to deploy a commit to the PostHog Team on Vercel.

A member of the Team first needs to authorize it.

@harshit078 harshit078 marked this pull request as ready for review December 11, 2025 14:51
Copy link
Copy Markdown
Contributor

@greptile-apps greptile-apps Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 files reviewed, no comments

Edit Code Review Agent Settings | Greptile

@harshit078
Copy link
Copy Markdown
Author

Hey @pauldambra , can you review the PR ? Thanks !

@lucasheriques lucasheriques self-requested a review December 15, 2025 20:56
Copy link
Copy Markdown
Contributor

hey Harshit! I'll review this one tomorrow - got stuck today fixing some other issues, but it's on my list

Copy link
Copy Markdown
Contributor

@lucasheriques lucasheriques left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR! The implementation looks good and the tests are solid.

One thing to clarify: since the Node SDK uses in-memory storage, register() properties only persist for the lifetime of the PostHog client instance. This is useful for long-running processes (Express servers, workers) but won't help in serverless environments where each invocation creates a new client.

Before merging, could you:

  1. Run pnpm changeset to generate a changeset (I see it's unchecked in the PR checklist)
  2. Add JSDoc to the register() method in the Node SDK explaining the behavior:
  3. Optionally, a docs update in the posthog.com repo (contents/docs/libraries/node/index.mdx) would be great but can be a follow-up

@harshit078
Copy link
Copy Markdown
Author

Hey @lucasheriques , sure I'll do the 3 steps and update the PR. Thanks !

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jan 5, 2026

This PR hasn't seen activity in a week! Should it be merged, closed, or further worked on? If you want to keep it open, post a comment or remove the stale label – otherwise this will be closed in another week.

@github-actions github-actions Bot added the stale label Jan 5, 2026
@github-actions
Copy link
Copy Markdown
Contributor

This PR hasn't seen activity in a week! Should it be merged, closed, or further worked on? If you want to keep it open, post a comment or remove the stale label – otherwise this will be closed in another week.

@github-actions github-actions Bot added stale and removed stale labels Jan 19, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 2, 2026

This PR hasn't seen activity in a week! Should it be merged, closed, or further worked on? If you want to keep it open, post a comment or remove the stale label – otherwise this will be closed in another week.

@github-actions github-actions Bot added the stale label Feb 2, 2026
@harshit078
Copy link
Copy Markdown
Author

Hey @lucasheriques, I've updated the changeset as required. If needed this PR can be reviewed again. Thanks !

@github-actions github-actions Bot removed the stale label Feb 3, 2026
@github-actions
Copy link
Copy Markdown
Contributor

This PR hasn't seen activity in a week! Should it be merged, closed, or further worked on? If you want to keep it open, post a comment or remove the stale label – otherwise this will be closed in another week.

@github-actions github-actions Bot added the stale label Feb 10, 2026
@github-actions
Copy link
Copy Markdown
Contributor

This PR was closed due to lack of activity. Feel free to reopen if it's still relevant.

@github-actions github-actions Bot closed this Feb 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants