hugo-theme-contentful/recipes/twitter-cards/index.html

118 lines
5.9 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html lang="en-us"><title>Twitter cards</title>
<link rel="stylesheet" href="https://foo-dogsquared.github.io/hugo-theme-contentful/css/main.min.ac4668a81007ca38fcac8e88436ad4fa6a969ee4ce9352f52f795abf04e1624a.css" /><meta name="generator" content="Hugo 0.76.0" />
<meta charset="utf-8">
<meta name="author" content="" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="referrer" content="no-referrer" />
<meta name="description" content="This will add Twitter cards for your webpages. (Be sure to copy the head partial first in your own layout folder.)
Thankfully, Hugo already has an internal template for Twitter cards. Simply add {{- template &#34;_internal/twitter_cards.html&#34; . -}} somewhere in your own copy. (For reference, heres the source code for the internal template.)
You could also roll your own Twitter cards but I recommend to modify the internal template instead fitting your specific needs." /><meta name="twitter:card" content="summary"/>
<meta name="twitter:title" content="Twitter cards"/>
<meta name="twitter:description" content="This will add Twitter cards for your webpages. (Be sure to copy the head partial first in your own layout folder.)
Thankfully, Hugo already has an internal template for Twitter cards. Simply add {{- template &#34;_internal/twitter_cards.html&#34; . -}} somewhere in your own copy. (For reference, heres the source code for the internal template.)
You could also roll your own Twitter cards but I recommend to modify the internal template instead fitting your specific needs."/>
<meta property="og:title" content="Twitter cards" />
<meta property="og:description" content="This will add Twitter cards for your webpages. (Be sure to copy the head partial first in your own layout folder.)
Thankfully, Hugo already has an internal template for Twitter cards. Simply add {{- template &#34;_internal/twitter_cards.html&#34; . -}} somewhere in your own copy. (For reference, heres the source code for the internal template.)
You could also roll your own Twitter cards but I recommend to modify the internal template instead fitting your specific needs." />
<meta property="og:type" content="article" />
<meta property="og:url" content="https://foo-dogsquared.github.io/hugo-theme-contentful/recipes/twitter-cards/" />
<meta property="article:published_time" content="2020-10-20T20:31:32+08:00" />
<meta property="article:modified_time" content="2020-10-24T15:49:14+08:00" />
<link rel="canonical" type="text/html" href="https://foo-dogsquared.github.io/hugo-theme-contentful/recipes/twitter-cards/" />
<script>
const theme = window.localStorage.getItem('theme');
if (theme) {
document.documentElement.dataset.theme = theme;
}
</script>
<body><nav aria-label="Primary navigation">
<a class="site__title" href="https://foo-dogsquared.github.io/hugo-theme-contentful/">Contentful</a>
<div class="site__links">
|
<a href="https://foo-dogsquared.github.io/hugo-theme-contentful/about/">About</a> |
<a href="https://foo-dogsquared.github.io/hugo-theme-contentful/categories/">Categories</a> |
<a href="https://foo-dogsquared.github.io/hugo-theme-contentful/recipes/">Recipes</a> |
<a href="https://foo-dogsquared.github.io/hugo-theme-contentful/tags/">Tags</a> |
</div>
<button class="site__theme-btn" aria-label="theme-toggle" onclick="const theme = window.localStorage.getItem('theme') == 'dark' ? 'light' : 'dark'; window.localStorage.setItem('theme', theme); document.documentElement.dataset.theme = theme">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
<path d="M0 12c0 6.627 5.373 12 12 12s12-5.373 12-12-5.373-12-12-12-12 5.373-12 12zm2 0c0-5.514 4.486-10 10-10v20c-5.514 0-10-4.486-10-10z"></path>
</svg>
</button>
</nav>
<article>
<header>
<h1>Twitter cards</h1>
</header>
<div class="post__meta">
<p data-content-publication-date="2020-10-20 20:31:32 &#43;0800 &#43;0800">Created: <time datetime="2020-10-20">2020-10-20</time></p>
<p data-content-modification-date="2020-10-24 15:49:14 &#43;0800 &#43;0800">Updated: <time datetime="2020-10-24">2020-10-24</time></p>
</div>
<hr>
<style>
#TableOfContents:not(:empty)::before {
content: "Table of contents";
font-weight: bold;
}
</style>
<nav id="TableOfContents"></nav>
<main>
<div class="paragraph">
<p>This will add <a href="https://developer.twitter.com/en/docs/tweets/optimize-with-cards/guides/getting-started">Twitter cards</a> for your webpages.
(Be sure to copy the <code>head</code> partial first in your own layout folder.)</p>
</div>
<div class="paragraph">
<p>Thankfully, Hugo already has <a href="https://gohugo.io/templates/internal/#twitter-cards">an internal template for Twitter cards</a>.
Simply add <code>{{- template &#34;_internal/twitter_cards.html&#34; . -}}</code> somewhere in your own copy.
(For reference, <a href="https://github.com/gohugoio/hugo/blob/25a6b33693992e8c6d9c35bc1e781ce3e2bca4be/tpl/tplimpl/embedded/templates/twitter_cards.html">heres the source code for the internal template</a>.)</p>
</div>
<div class="paragraph">
<p>You could also roll your own Twitter cards but I recommend to modify the internal template instead fitting your specific needs.
(Copy the internal template from the given link, create it as a partial in <code>layouts/partials/twitter_cards.html</code>, modify it, and insert the template with <code>{{- partial &#34;twitter_cards.html&#34; -}}</code>.)</p>
</div>
</main>
</article>
<hr>
<footer>
<p><a href="https://foo-dogsquared.github.io/hugo-theme-contentful/">Back to home</a></p>
</footer>
<p>Available in other languages:
<span class="site__languages">|
<a href="/hugo-theme-contentful/en">English</a> |
<a href="/hugo-theme-contentful/tl">Tagalog</a> |
</span>
</p>
<p>© 2021 Contentful</p>
</body>
</html>