mirror of
https://github.com/Extroonie/extroonie.com.git
synced 2026-07-07 07:06:42 -07:00
feat: enhance open graph meta tags
This commit is contained in:
parent
c8e07246fb
commit
688445f9ad
1 changed files with 7 additions and 2 deletions
|
|
@ -24,7 +24,7 @@
|
||||||
|
|
||||||
<meta
|
<meta
|
||||||
property="og:title"
|
property="og:title"
|
||||||
content="{{ if .IsHome }}{{ .Site.Title }}{{ else }}{{ .Title }} | {{ .Site.Title }}{{ end }}"
|
content="{{ if .IsHome }}{{ .Site.Params.author }}{{ else }}{{ .Title }}{{ end }}"
|
||||||
/>
|
/>
|
||||||
<meta
|
<meta
|
||||||
property="og:description"
|
property="og:description"
|
||||||
|
|
@ -35,11 +35,16 @@
|
||||||
content="{{ if .IsPage }}article{{ else }}website{{ end }}"
|
content="{{ if .IsPage }}article{{ else }}website{{ end }}"
|
||||||
/>
|
/>
|
||||||
<meta property="og:url" content="{{ .Permalink }}" />
|
<meta property="og:url" content="{{ .Permalink }}" />
|
||||||
<meta property="og:site_name" content="{{ .Site.Title }}" />
|
{{ with .Site.Params.images }}
|
||||||
|
<meta property="og:image" content="{{ $.Site.BaseURL }}{{ index . 0 }}" />
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
<meta name="twitter:card" content="summary" />
|
<meta name="twitter:card" content="summary" />
|
||||||
<meta name="twitter:site" content="@{{ .Site.Params.social.twitter }}" />
|
<meta name="twitter:site" content="@{{ .Site.Params.social.twitter }}" />
|
||||||
<meta name="twitter:creator" content="@{{ .Site.Params.social.twitter }}" />
|
<meta name="twitter:creator" content="@{{ .Site.Params.social.twitter }}" />
|
||||||
|
{{ with .Site.Params.images }}
|
||||||
|
<meta name="twitter:image" content="{{ $.Site.BaseURL }}{{ index . 0 }}" />
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
<link rel="canonical" href="{{ .Permalink }}" />
|
<link rel="canonical" href="{{ .Permalink }}" />
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue