Skip to content

Added social_url helper#572

Merged
ronaldlangeveld merged 1 commit intomainfrom
social_urls_helper
Apr 17, 2025
Merged

Added social_url helper#572
ronaldlangeveld merged 1 commit intomainfrom
social_urls_helper

Conversation

@ErisDS
Copy link
Copy Markdown
Member

@ErisDS ErisDS commented Apr 16, 2025

ref https://linear.app/ghost/issue/PLG-412/create-template-helpers

  • Instead of duplicating facebook_url and twitter_url we're creating a new social_url helper that takes a social type and then outputs the right url
  • It uses the context provided, the expected usage would be {{#if bluesky}}
    <a class="gh-author-bluesky" href="{{social_url type="bluesky"}}" target="_blank" rel="noopener">{{> icons/bluesky}} {{/if}}

ref https://linear.app/ghost/issue/PLG-412/create-template-helpers

- Instead of duplicating facebook_url and twitter_url we're creating a new
  social_url helper that takes a social type and then outputs the right url
- It uses the context provided, the expected usage would be
{{#if bluesky}}
  <a class="gh-author-bluesky" href="{{social_url type="bluesky"}}" target="_blank" rel="noopener">{{> icons/bluesky}}</a>
{{/if}}
@ErisDS ErisDS force-pushed the social_urls_helper branch from 09fd807 to e4c57a3 Compare April 16, 2025 21:10
@ronaldlangeveld ronaldlangeveld merged commit 57e94ec into main Apr 17, 2025
2 checks passed
@ronaldlangeveld ronaldlangeveld deleted the social_urls_helper branch April 17, 2025 05:10
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.

2 participants