blob: c2bc1874ab2bb6fd49b0f98aca09521ffe5c3905 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
<meta property="og:title" content="{{ title .Title }}" />
<meta name="twitter:title" content="{{ .Title }}"/>
<meta itemprop="name" content="{{ .Title }}">
<meta property="article:published_time" content="{{ dateFormat "2006-01-02T15:04:05Z07:00" .Date }}" />
<meta property="article:modified_time" content="{{ dateFormat "2006-01-02T15:04:05Z07:00" .Lastmod }}" />
<meta property="og:updated_time" content="{{ dateFormat "2006-01-02T15:04:05Z07:00" .Lastmod }}" />
{{- with .Site.Title -}}<meta property="og:site_name" content="{{ . }}" />{{- end -}}
{{- with .Params.locale -}}<meta property="og:locale" content="{{ . }}" />{{- end -}}
{{- if .IsHome -}}
{{ with .Site.Params.feed.itunes_summary -}}
<meta property="og:description" content="{{ . }}" />
<meta name="twitter:description" content="{{ . }}" />
<meta itemprop="description" content="{{ . }}" />
{{- else -}}
<meta property="og:description" content="{{ $.Site.Title }}" />
<meta name="twitter:description" content="{{ $.Site.Title }}" />
<meta itemprop="description" content="{{ $.Site.Title }}" />
{{- end -}}
{{- else -}}
<meta property="og:description" content="{{ if .Description }}{{ .Description }}{{ else }}{{if .IsPage}}{{ .Summary }}{{ end }}{{ end }}" />
<meta name="twitter:description" content="{{ if .Description }}{{ .Description }}{{ else }}{{if .IsPage}}{{ .Summary }}{{ end }}{{ end }}" />
<meta itemprop="description" content="{{ if .Description }}{{ .Description }}{{ else }}{{if .IsPage}}{{ .Summary }}{{ end }}{{ end }}">
{{- end -}}
{{ with .Site.Params.social.twitter }}<meta name="twitter:site" content="@{{ . }}"/>{{ end }}
{{ with .Site.Params.social.twitter }}<meta name="twitter:creator" content="@{{ . }}"/>{{ end }}
{{ with .Site.Params.social.twitter_domain }}<meta name="twitter:domain" content="{{ . }}"/>{{ end }}
{{ if eq .Type "episode" }}
<meta property="og:type" content="article" />
{{- else if .Params.type -}}
<meta property="og:type" content="{{ .Params.type }}" />
{{- else -}}
<meta property="og:type" content="website" />
{{ end }}
<meta property="og:url" content="{{ .Permalink | relURL }}" />
{{ with .Params.images }}{{ range first 1 . }}
<meta name="twitter:card" content="summary_large_image" />
{{ if (eq (slicestr . 0 4) "http") }}
<meta property="og:image" content="{{ . }}"/>
<meta name="twitter:image" content="{{ . }}" />
<meta itemprop="image" content="{{ . }}" />
{{ else }}
<meta property="og:image" content="{{ $.Site.BaseURL}}/{{ . }}" />
<meta name="twitter:image" content="{{ $.Site.BaseURL}}/{{ . }}"/>
<meta itemprop="image" content="{{ $.Site.BaseURL}}/{{ . }}" />
{{ end }}
{{ end }}{{ end }}
<!-- Facebook Page Admin ID for Domain Insights -->
{{ with .Site.Params.social.facebook_admin }}
{{ range . }}
<meta property="fb:admins" content="{{ . }}" />
{{ end }}
{{ end }}
|