DEV Community

Michael Tharrington Subscriber for The DEV Team

Posted on • Updated on

Lesser Known Features of DEV — Embedding Call To Action (CTA) Buttons

Did you realize that on DEV you have the ability to embed a call-to-action button? For example, it looks like this:

Learn about Community Moderation on DEV

Want to know how it's done? I got you covered! 😎

Creating an Embedded CTA Button

Embedding a CTA button in your posts is super simple, just use the following Markdown syntax:

{% cta link %} description {% endcta %}

To be clear, the example embed I created at the top of this article looks like this:

{% cta https://dev.to/community-moderation %} Learn about Community Moderation on DEV {% endcta %}

This isn't our only available embed... we have plenty others described in our Editor Guide that behave in interesting ways. For instance, here's an embed that points to my profile:

The syntax for that one is as such:

{% embed https://dev.to/michaeltharrington %}

What Might I Use This For? 🤔

Loads of things! Maybe you wanna point folks to your personal portfolio or blog. Perhaps you'd like for folks to sign up to your newsletter. Or, maybe you recently released a book and would like for others to check it out. Go for it! These are all valid uses for a CTA button.

Just make sure that your description is accurate for whatever it is linking to. Of course, please don't mislead folks or send them to a link that automatically takes action... that won't win you any friends and could result in us unpublishing your content or taking disciplinary action against your account.

That's a Wrap

If you have any question about this feature or others, don't hesitate to hit me up in the comments. Now, feel free to embed away and hope ya enjoy your day! 🙌

Top comments (10)

Collapse
 
erinposting profile image
Erin Bensinger

Love this feature! Thanks for pointing it out 😁

I'm going to give it a try... ahem

Once you're ready to incorporate these lesser-known features into an amazing post on DEV, check out the Best Practices for Writing on DEV series to sharpen your technical writing skills!

Best Practices for Writing on DEV

How did I do?!

Collapse
 
michaeltharrington profile image
Michael Tharrington

Woot! You're most welcome. And ya did well. 🙌

Also, such a great series to point out!

Collapse
 
perssondennis profile image
Dennis Persson

Sometimes is suitable with a button

Check out #jokes tag

And sometimes it's better with embedding the page as is

#jokes

plz post the lols

Which do you prefer?

Personally I prefer the cta button!

Collapse
 
j3ffjessie profile image
J3ffJessie
Collapse
 
ben profile image
Ben Halpern
Collapse
 
somedood profile image
Basti Ortiz

Hmm... #todayilearned 🤯

Collapse
 
bhendi profile image
Jyothikrishna

Eagerly waiting for the fourth part

Collapse
 
aatmaj profile image
Aatmaj

Love this feature! Thanks for this blog😍

Lets try it out 😉

Follow me on Github!

Collapse
 
michaeltharrington profile image
Michael Tharrington

Awww yeah, happy to help! And perfect usage. 🙌

Collapse
 
mrdjohnson profile image
DJ Johnson

Is there a way to get a CTA to look like any other link?

I'm trying to link to a non http url (example://this_is_a_valid_url), but it gets converted to (example//this_is_a_valid_url) which does not take me where I want to go, I can use a CTA but its rather larger, Suggestions?