docs: add campaign personalization guide#374
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.
WalkthroughUpdated documentation navigation and content: apps/docs/docs.json was modified to add "guides/campaign-personalization" to the Guides group. A new file apps/docs/guides/campaign-personalization.mdx was added, documenting contact-variable workflow, built-in and custom variables, dashboard setup, API examples, fallback syntax, and best practices. apps/docs/guides/double-opt-in.mdx was edited to adjust whitespace in the confirmation URL placeholder and replace a multi-accordion best-practices section with a static Markdown table. 🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Deploying usesend with
|
| Latest commit: |
3ea37d7
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://26423578.usesend.pages.dev |
| Branch Preview URL: | https://docs-campaign-personalizatio.usesend.pages.dev |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
apps/docs/guides/double-opt-in.mdx (1)
128-137:⚠️ Potential issue | 🟡 MinorInconsistent variable format between table and warning.
Line 128 documents the variable as
{{doubleOptInUrl}}(no spaces), while line 134 uses{{ doubleOptInUrl }}(with spaces). While both formats work (the regex uses\s*for whitespace tolerance perapps/web/src/lib/constants/double-opt-in.ts:67-68), the documentation should be consistent to avoid reader confusion.Proposed fix: use consistent spacing
Pick one format and apply it to both locations. If choosing no spaces:
- The `{{ doubleOptInUrl }}` variable is **required** in the email template. The + The `{{doubleOptInUrl}}` variable is **required** in the email template. The🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@apps/docs/guides/double-opt-in.mdx` around lines 128 - 137, The documentation shows inconsistent spacing for the doubleOptInUrl template variable (table uses `{{doubleOptInUrl}}` while the Warning uses `{{ doubleOptInUrl }}`); pick one canonical format (preferably no spaces: `{{doubleOptInUrl}}`) and update the Warning block to match the table. Make sure to adjust both occurrences in apps/docs/guides/double-opt-in.mdx and keep aware that the parsing regex in apps/web/src/lib/constants/double-opt-in.ts (around the regex at lines referenced) already tolerates whitespace, so no code changes are needed.
🧹 Nitpick comments (1)
apps/docs/guides/campaign-personalization.mdx (1)
165-165: Minor style: "empty spaces" is redundant.Per LanguageTool, "empty spaces" is redundant since spaces are inherently empty. Consider simplifying to "blank spaces" or "gaps".
Proposed fix
-| Use fallbacks for optional data | Prevents awkward empty spaces when a contact is missing a value | +| Use fallbacks for optional data | Prevents awkward gaps when a contact is missing a value |🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@apps/docs/guides/campaign-personalization.mdx` at line 165, Replace the redundant phrase "empty spaces" in the table row text "Prevent awkward empty spaces when a contact is missing a value" with a simpler term such as "gaps" or "blank spaces" (e.g., change it to "Prevent awkward gaps when a contact is missing a value") so the wording is concise and non-redundant; update the string in the docs where that exact table row appears.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Outside diff comments:
In `@apps/docs/guides/double-opt-in.mdx`:
- Around line 128-137: The documentation shows inconsistent spacing for the
doubleOptInUrl template variable (table uses `{{doubleOptInUrl}}` while the
Warning uses `{{ doubleOptInUrl }}`); pick one canonical format (preferably no
spaces: `{{doubleOptInUrl}}`) and update the Warning block to match the table.
Make sure to adjust both occurrences in apps/docs/guides/double-opt-in.mdx and
keep aware that the parsing regex in apps/web/src/lib/constants/double-opt-in.ts
(around the regex at lines referenced) already tolerates whitespace, so no code
changes are needed.
---
Nitpick comments:
In `@apps/docs/guides/campaign-personalization.mdx`:
- Line 165: Replace the redundant phrase "empty spaces" in the table row text
"Prevent awkward empty spaces when a contact is missing a value" with a simpler
term such as "gaps" or "blank spaces" (e.g., change it to "Prevent awkward gaps
when a contact is missing a value") so the wording is concise and non-redundant;
update the string in the docs where that exact table row appears.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 3f81daf0-998d-4074-b86a-8a5bc6e4ad2e
📒 Files selected for processing (2)
apps/docs/guides/campaign-personalization.mdxapps/docs/guides/double-opt-in.mdx
Summary
Verification
Summary by cubic
Adds a new campaign personalization guide and updates docs navigation. Also simplifies the Double Opt‑In best practices section (no accordions).
New Features
Refactors
{{ doubleOptInUrl }}formatting.Written for commit 3ea37d7. Summary will update on new commits.
Summary by CodeRabbit