Skip to content

Fix social_url helper fallback documentation#61

Merged
ErisDS merged 1 commit into
mainfrom
docs/sitewide-social-urls
May 13, 2026
Merged

Fix social_url helper fallback documentation#61
ErisDS merged 1 commit into
mainfrom
docs/sitewide-social-urls

Conversation

@ErisDS
Copy link
Copy Markdown
Member

@ErisDS ErisDS commented May 13, 2026

Summary

Fixes the now-outdated fallback documentation for {{social_url}}. The helper now falls back to sitewide @site values for all 9 social platforms — not just Facebook and Twitter — since the rest were added to Settings > General > Social accounts a couple of weeks ago.

Changes

  • themes/helpers/data/social_url.mdx — Replaces the two-paragraph claim that "facebook and twitter fall back; the rest output nothing" with the actual behaviour ("when called inside an author scope, looks up on the current author first, then falls back to @site; outside an author scope, reads from @site directly"). Updates the "globally available" example to reflect that all platforms work the same way, not just Facebook and Twitter.

Not in this PR

A follow-up will document the new {{#social_accounts}} block helper (merged in TryGhost/Ghost#27834, not yet shipped) — see #62.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 13, 2026

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: 80fdcd48-2c45-4bf2-83f5-1a582489f257

📥 Commits

Reviewing files that changed from the base of the PR and between 69bb2b0 and 9135cde.

📒 Files selected for processing (1)
  • themes/helpers/data/social_url.mdx

Walkthrough

The pull request updates the social_url helper documentation in themes/helpers/data/social_url.mdx. The behavior description now explicitly documents the type argument and clarifies the resolution order: within an author scope, the helper checks the current author first before falling back to sitewide @site values; outside an author scope, it reads directly from @site. The documentation also clarifies that all supported platforms are configurable both per-author and sitewide. The sitewide usage example has been expanded to demonstrate multiple platforms—twitter (X), bluesky, and linkedin—instead of only twitter and facebook.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the main change: fixing outdated documentation about the social_url helper's fallback behavior for social platform URLs.
Description check ✅ Passed The description accurately explains the changes made, specifying which file was modified and what the documentation updates address regarding social platform fallback behavior.
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 docs/sitewide-social-urls

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

@mintlify
Copy link
Copy Markdown
Contributor

mintlify Bot commented May 13, 2026

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

Project Status Preview Updated (UTC)
Ghost 🟢 Ready View Preview May 13, 2026, 10:27 AM

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

The {{social_url}} helper now falls back to sitewide @site values for all 9 platforms (previously only Facebook and Twitter). Bluesky, Instagram, LinkedIn, Mastodon, Threads, TikTok and YouTube are all configurable both per-author and sitewide under Settings > General > Social accounts.
@ErisDS ErisDS force-pushed the docs/sitewide-social-urls branch from 69bb2b0 to 9135cde Compare May 13, 2026 11:09
@ErisDS ErisDS changed the title Document sitewide social account fields Fix social_url helper fallback documentation May 13, 2026
@ErisDS ErisDS merged commit 0e3674a into main May 13, 2026
2 checks passed
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