Skip to content

Commit 0de5ded

Browse files
committed
fix seo meta title
1 parent ebbbd88 commit 0de5ded

7 files changed

Lines changed: 178 additions & 66 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
_site/
12
site/
23
*.local
34
.DS_Store

src/_data/site.json

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
{
2-
"name": "Belajarpython – Situs Open Source Tutorial Pemrograman Python Bahasa Indonesia",
2+
"name": "Belajarpython.com",
3+
"tagline": "Tutorial Python Bahasa Indonesia Lengkap untuk Pemula sampai Mahir",
34
"author": "Purwanto",
4-
"url": "https://belajarpython.com"
5+
"url": "https://belajarpython.com",
6+
"description": "Belajar Python gratis dengan tutorial lengkap berbahasa Indonesia. Panduan pemrograman Python dari dasar hingga mahir: data science, machine learning, AI, dan web development. Dipercaya 100+ kampus & perusahaan di Indonesia.",
7+
"keywords": "belajar python, tutorial python, python indonesia, belajar python pemula, kursus python gratis, pemrograman python, python untuk data science, python machine learning"
58
}

src/_includes/head.njk

Lines changed: 119 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,137 @@
11
<head>
22
<meta charset="UTF-8" />
3-
<meta name="robots" content="index,follow" />
4-
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" />
5-
<meta name="author" content="Belajarpython" />
6-
<meta name="language" content="Indonesia" />
7-
<meta name="description" content="{% if description %}{{ description }}{% else %}Belajarpython adalah situs terbuka (open source) yang dikembangkan oleh developer untuk developer. Semua orang baik dari kalangan developer, mahasiswa, pengajar, bahkan anak kecil yang baru mempelajari bahasa pemrograman python bisa ikut memberikan kontribusinya{% endif %}">
3+
<meta name="robots" content="index,follow,max-image-preview:large,max-snippet:-1,max-video-preview:-1" />
4+
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=5.0" />
5+
<meta name="author" content="Belajarpython.com" />
6+
<meta name="language" content="id" />
7+
<meta name="geo.region" content="ID" />
8+
<meta name="geo.placename" content="Indonesia" />
9+
<meta name="description" content="{% if description %}{{ description }}{% else %}{{ site.description }}{% endif %}">
10+
<meta name="keywords" content="{{ site.keywords }}" />
811
<meta name="google-site-verification" content="" />
9-
<meta property="og:url" content="" />
10-
<meta property="og:title" content="{% if title %}{{ title }} - {% endif %}{{ site.name }}" />
12+
13+
<!-- Canonical URL -->
14+
<link rel="canonical" href="{{ site.url }}{{ page.url }}" />
15+
16+
<!-- Open Graph / Facebook -->
17+
<meta property="og:locale" content="id_ID" />
18+
<meta property="og:url" content="{{ site.url }}{{ page.url }}" />
19+
<meta property="og:site_name" content="{{ site.name }}" />
20+
<meta property="og:title" content="{% if isHomepage %}Tutorial Pemrograman Python Bahasa Indonesia | Dasar Sampai Advance {{ site.name }}{% elif title %}{{ title }} | {{ site.name }}{% else %}{{ site.name }}{% endif %}" />
1121
<meta property="og:type" content="website" />
12-
<meta property="og:description" content="Situs Open Source Tutorial Pemrograman Python" />
13-
<meta property="og:image" content="" />
14-
<meta name="twitter:description" content="Situs Open Source Tutorial Pemrograman Python" />
15-
<meta name="twitter:image:src" content="" />
16-
<meta name="twitter:title" content="{% if title %}{{ title }} - {% endif %}{{ site.name }}" />
22+
<meta property="og:description" content="{% if description %}{{ description }}{% else %}{{ site.description }}{% endif %}" />
23+
<meta property="og:image" content="{{ site.url }}/img/logos/logo-belajarpython-square.png" />
24+
<meta property="og:image:width" content="1200" />
25+
<meta property="og:image:height" content="630" />
26+
<meta property="og:image:alt" content="Belajarpython.com - Tutorial Python Bahasa Indonesia" />
27+
28+
<!-- Twitter Card -->
1729
<meta name="twitter:card" content="summary_large_image" />
18-
<meta name="twitter:site" content="Belajarpython.com" />
19-
<meta name="twitter:creator" content="Belajarpython" />
30+
<meta name="twitter:site" content="@belajarpythoncom" />
31+
<meta name="twitter:creator" content="@belajarpythoncom" />
32+
<meta name="twitter:title" content="{% if isHomepage %}Tutorial Pemrograman Python Bahasa Indonesia{% elif title %}{{ title }} | {{ site.name }}{% else %}{{ site.name }}{% endif %}" />
33+
<meta name="twitter:description" content="{% if description %}{{ description }}{% else %}{{ site.description }}{% endif %}" />
34+
<meta name="twitter:image" content="{{ site.url }}/img/logos/logo-belajarpython-square.png" />
35+
36+
<!-- Favicon & Theme -->
2037
<link rel="icon" href="/img/favicon.png" />
38+
<link rel="apple-touch-icon" href="/img/favicon.png" />
2139
<meta name="theme-color" content="#2a5880" />
40+
<meta name="msapplication-TileColor" content="#2a5880" />
41+
42+
<!-- Verification -->
2243
<meta name="msvalidate.01" content="8CFBF57F61ECFF6C84740E37B7FCDE15" />
44+
45+
<!-- Styles -->
2346
<link rel="stylesheet" type="text/css" href="/css/base.css?v=1.2.8" />
2447
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.7.0/styles/atom-one-dark-reasonable.min.css">
2548
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.9.0/highlight.min.js" integrity="sha512-D9gUyxqja7hBtkWpPWGt9wfbfaMGVt9gnyCvYa+jojwwPHLCzUm5i8rpk7vD7wNee9bA35eYIjobYPaQuKS1MQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
2649
<script>hljs.initHighlightingOnLoad();</script>
50+
51+
<!-- Structured Data / Schema.org -->
52+
{% if isHomepage %}
2753
<script type="application/ld+json">
2854
{
29-
"@context": "http://schema.org",
55+
"@context": "https://schema.org",
3056
"@type": "WebSite",
31-
"url": "https://belajarpython.com",
32-
"name": "{% if title %}{{ title }}{% endif %}",
33-
"description": "{{ site.name }}"
57+
"@id": "{{ site.url }}/#website",
58+
"url": "{{ site.url }}",
59+
"name": "{{ site.name }}",
60+
"description": "{{ site.description }}",
61+
"inLanguage": "id-ID",
62+
"potentialAction": {
63+
"@type": "SearchAction",
64+
"target": "{{ site.url }}/search?q={search_term_string}",
65+
"query-input": "required name=search_term_string"
66+
}
3467
}
3568
</script>
36-
<title>{% if title %}{{ title }} - {% endif %}{{ site.name }}</title>
69+
<script type="application/ld+json">
70+
{
71+
"@context": "https://schema.org",
72+
"@type": "EducationalOrganization",
73+
"@id": "{{ site.url }}/#organization",
74+
"name": "{{ site.name }}",
75+
"url": "{{ site.url }}",
76+
"logo": "{{ site.url }}/img/logos/logo-belajarpython-square.png",
77+
"description": "{{ site.tagline }}",
78+
"foundingDate": "2015",
79+
"sameAs": [
80+
"https://github.com/belajarpythoncom"
81+
],
82+
"areaServed": {
83+
"@type": "Country",
84+
"name": "Indonesia"
85+
},
86+
"teaches": [
87+
"Python Programming",
88+
"Data Science",
89+
"Machine Learning",
90+
"Web Development"
91+
]
92+
}
93+
</script>
94+
<script type="application/ld+json">
95+
{
96+
"@context": "https://schema.org",
97+
"@type": "ItemList",
98+
"itemListElement": [
99+
{
100+
"@type": "Course",
101+
"position": 1,
102+
"name": "Tutorial Python Dasar",
103+
"description": "Pelajari dasar-dasar pemrograman Python dari instalasi hingga konsep OOP",
104+
"provider": {
105+
"@type": "Organization",
106+
"name": "{{ site.name }}"
107+
},
108+
"educationalLevel": "Beginner",
109+
"inLanguage": "id",
110+
"isAccessibleForFree": true
111+
}
112+
]
113+
}
114+
</script>
115+
{% else %}
116+
<script type="application/ld+json">
117+
{
118+
"@context": "https://schema.org",
119+
"@type": "Article",
120+
"headline": "{{ title }}",
121+
"description": "{% if description %}{{ description }}{% else %}{{ site.description }}{% endif %}",
122+
"url": "{{ site.url }}{{ page.url }}",
123+
"inLanguage": "id-ID",
124+
"publisher": {
125+
"@type": "Organization",
126+
"name": "{{ site.name }}",
127+
"logo": {
128+
"@type": "ImageObject",
129+
"url": "{{ site.url }}/img/logos/logo-belajarpython-square.png"
130+
}
131+
}
132+
}
133+
</script>
134+
{% endif %}
135+
136+
<title>{% if isHomepage %}Belajarpython - Tutorial Pemrograman Python Bahasa Indonesia Terbaru 2026{% elif isTutorial %}{{ title }} - Tutorial Lengkap Dasar Sampai Advance{% elif title %}{{ title }} | {{ site.name }}{% else %}{{ site.name }}{% endif %}</title>
37137
</head>

0 commit comments

Comments
 (0)