Snipt Blog

#42140

Embed YouTube and Vimeo videos into your Markdown-flavored Snipts

Update: view the full Snipt blogging documentation here.

Dave Stanton on Twitter thought it'd be awesome to embed YouTube videos directly into his Snipt-powered blog posts.

Seemed like a simple-enough request.

When you're in your Markdown snipt, adding this custom tag will automatically embed a YouTube video with the desired dimensions:

[[youtube-{video_id}-{width}x{height}]]

Where {video_id} is replaced with something like K7vU2cDIyjU (you can grab the ID in the URL of any YouTube video). {width} would be replaced with a width value like 688 and {height} with something like 387.

For Vimeo video:

[[vimeo-{video_id}-{width}x{height}]]

Note: embedding videos makes list-view of snipts sometimes chop off half the video. If you have a blog post that you'd like to force an "always expanded" view in the list-view, simply add the tag "snipt-expand" to the snipt.

https://snipt.net/embed/06ad62e1486b029a4c2b78ac68d86870/
https://snipt.net/raw/06ad62e1486b029a4c2b78ac68d86870/
06ad62e1486b029a4c2b78ac68d86870
markdown
Markdown
23
2014-04-19T23:42:00
True
True
Jun 12, 2012 at 10:38 AM
/api/public/snipt/42140/
embed-youtube-videos-into-your-markdown-flavored-snipts
<p><strong>Update:</strong> view the full <a href="https://snipt.net/blogging/">Snipt blogging documentation here</a>.</p> <p><a href="http://twitter.com/gotoplanb">Dave Stanton</a> on Twitter thought it'd be awesome to embed YouTube videos directly into his <a href="https://blog.snipt.net/announcing-the-sniptnet-blogging-platform/">Snipt-powered blog posts</a>.</p> <p>Seemed like a simple-enough request.</p> <p>When you're in your Markdown snipt, adding this custom tag will automatically embed a YouTube video with the desired dimensions:</p> <pre><code>[[youtube-{video_id}-{width}x{height}]] </code></pre> <p>Where <code>{video_id}</code> is replaced with something like <code>K7vU2cDIyjU</code> (you can grab the ID in the URL of any YouTube video). <code>{width}</code> would be replaced with a width value like <code>688</code> and <code>{height}</code> with something like <code>387</code>.</p> <p>For Vimeo video:</p> <pre><code>[[vimeo-{video_id}-{width}x{height}]] </code></pre> <p>Note: embedding videos makes list-view of snipts sometimes chop off half the video. If you have a blog post that you'd like to force an "always expanded" view in the list-view, simply add the tag "snipt-expand" to the snipt.</p>
"June 2012", 2012, blog