-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
/
Copy pathastro.config.mjs
124 lines (120 loc) · 2.85 KB
/
astro.config.mjs
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
import starlight from '@astrojs/starlight';
import { defineConfig } from 'astro/config';
import svelte from '@astrojs/svelte';
import vercel from '@astrojs/vercel/serverless';
export const locales = {
root: {
label: 'English',
lang: 'en'
},
es: {
label: 'Español',
lang: 'es'
},
fr: {
label: 'Français',
lang: 'fr'
},
pt: {
label: 'Português',
lang: 'pt'
},
ru: {
label: 'Русский',
lang: 'ru'
},
'zh-cn': {
label: '简体中文',
lang: 'zh-CN'
}
};
// https://astro.build/config
export default defineConfig({
integrations: [starlight({
title: 'Angular Challenges',
logo: {
src: './public/angular-challenge.webp',
alt: 'angular challenges logo'
},
favicon: './angular-challenge.ico',
social: {
github: 'https://github.com/tomalaforge/angular-challenges',
linkedin: 'https://www.linkedin.com/in/thomas-laforge-2b05a945/',
twitter: 'https://twitter.com/laforge_toma'
},
customCss: ['./src/styles/custom-css.css'],
sidebar: [{
label: 'Guides',
autogenerate: {
directory: 'guides'
},
translations: {
es: 'Guías',
fr: 'Guides',
pt: 'Guias',
ru: 'Руководство',
'zh-CN': '指南'
}
},
{
label: 'Leaderboard',
autogenerate: {
directory: 'leaderboard',
collapsed: true
},
translations: {
es: 'Leaderboard',
fr: 'Leaderboard',
pt: 'Tabela de Classificação',
ru: 'Leaderboard',
'zh-CN': '排行榜'
}
},
{
label: 'Challenges',
autogenerate: {
directory: 'challenges'
},
translations: {
es: 'Desafíos',
fr: 'Challenges',
pt: 'Desafios',
ru: 'Задачи',
'zh-CN': '挑战'
}
}],
head: [{
tag: 'script',
attrs: {
src: 'https://www.googletagmanager.com/gtag/js?id=G-6BXJ62W6G5',
async: true
}
}, {
tag: 'script',
content: `
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-6BXJ62W6G5');
`
}, {
tag: 'script',
attrs: {
src: 'https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-2438923752868254',
async: true
}
}],
components: {
MarkdownContent: './src/components/Content.astro',
TableOfContents: './src/components/TableOfContents.astro',
PageTitle: './src/components/PageTitle.astro',
MobileMenuFooter: './src/components/MobileMenuFooter.astro',
SiteTitle: './src/components/SiteTitle.astro',
Hero: './src/components/Hero.astro'
},
defaultLocale: 'root',
locales
}), svelte()],
output: "hybrid",
adapter: vercel()
});