Skip to content

docs: fix Node visitor tracking snippet#145

Open
leo-paz wants to merge 1 commit into
mainfrom
leo/sdk-public-api-docs-doctest-sweep
Open

docs: fix Node visitor tracking snippet#145
leo-paz wants to merge 1 commit into
mainfrom
leo/sdk-public-api-docs-doctest-sweep

Conversation

@leo-paz

@leo-paz leo-paz commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Initialize the @outlit/node client in the React Native visitor tracking snippet before using outlit.track() / outlit.identify().

Verification

  • bun run typecheck
  • Focused docs stale-example scan for Node SDK private-key/event-field patterns and manual engaged/inactive code fences
  • Isolated TypeScript compile of the repaired Node snippet with workspace path aliases

Note: this repo has no staging branch, so this PR targets main.

Summary by CodeRabbit

Documentation

  • Updated example code demonstrating proper initialization of the tracking client before using fingerprint tracking and user identification features.

@coderabbitai

coderabbitai Bot commented Jun 12, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 16837d37-1c07-44e9-a98a-c864854bd8cb

📥 Commits

Reviewing files that changed from the base of the PR and between 29ca464 and 8c9bfec.

📒 Files selected for processing (1)
  • docs/concepts/website-visitors.mdx

Walkthrough

The Node.js example in docs/concepts/website-visitors.mdx now explicitly instantiates an Outlit client with a public key from the environment before demonstrating fingerprint tracking and identification calls.

Changes

Documentation Examples

Layer / File(s) Summary
Node.js Outlit client instantiation example
docs/concepts/website-visitors.mdx
Added const client = new Outlit({ publicKey: process.env.OUTLIT_KEY! }) initialization before the subsequent track() and identify() method calls in the Node.js code example.

Possibly related PRs

  • OutlitAI/outlit-sdk#143: Both PRs update MDX docs examples to construct an Outlit instance using publicKey: process.env.OUTLIT_KEY! (replacing prior server-key patterns) before calling tracking/fingerprinting/identify() APIs.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Poem

🐇 A line or two, so neat and small,
The client springs to life, that's all!
With public keys from env so bright,
The examples shine, now burning right! ✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'docs: fix Node visitor tracking snippet' accurately describes the main change in the PR: updating the Node.js React Native visitor tracking code example in the documentation.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch leo/sdk-public-api-docs-doctest-sweep

Comment @coderabbitai help to get the list of available commands and usage tips.

@mintlify

mintlify Bot commented Jun 12, 2026

Copy link
Copy Markdown

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
outlit 🟢 Ready View Preview Jun 12, 2026, 6:04 PM

💡 Tip: Enable Workflows to automatically generate PRs for you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant