-
Notifications
You must be signed in to change notification settings - Fork 87
Expand file tree
/
Copy pathastro.config.mjs
More file actions
120 lines (118 loc) · 3.24 KB
/
astro.config.mjs
File metadata and controls
120 lines (118 loc) · 3.24 KB
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
// @ts-check
import { defineConfig } from 'astro/config';
import starlight from '@astrojs/starlight';
import starlightLinksValidatorPlugin from 'starlight-links-validator';
import sitemap from '@astrojs/sitemap';
import { sidebar } from './src/sidebar.ts';
import { GOOGLE_DARK_THEME, GOOGLE_LIGHT_THEME } from './src/google-theme';
const site = 'https://genkit.dev';
const ogUrl = new URL('ogimage.png?v=1', site).href;
// https://astro.build/config
export default defineConfig({
// TODO: Update to genkit.dev before launch
site,
markdown: {
shikiConfig: {
langAlias: { dotprompt: 'handlebars' },
},
},
integrations: [
starlight({
favicon: 'favicon.ico',
expressiveCode: {
themes: [GOOGLE_DARK_THEME, GOOGLE_LIGHT_THEME],
tabWidth: 4,
},
pagination: false,
title: 'Genkit',
components: {
Sidebar: './src/components/sidebar.astro',
Header: './src/content/custom/header.astro',
Hero: './src/content/custom/hero.astro',
Head: './src/content/custom/head.astro',
TableOfContents: './src/components/LanguageAwareTableOfContents.astro',
},
head: [
{
tag: 'meta',
attrs: {
property: 'og:image',
content: ogUrl,
width: '1085',
height: '377',
},
},
{
tag: 'link',
attrs: {
href: 'https://fonts.gstatic.com',
rel: 'preconnect',
crossorigin: true,
},
},
{
tag: 'link',
attrs: {
href: 'https://fonts.googleapis.com/css2?family=Google+Sans:wght@400;500&display=swap',
rel: 'stylesheet',
},
},
{
tag: 'link',
attrs: {
href: 'https://fonts.googleapis.com/css2?family=Google+Sans+Text:wght@400;500&display=swap',
rel: 'stylesheet',
},
},
{
tag: 'link',
attrs: {
href: 'https://fonts.googleapis.com/css2?family=Google+Sans+Mono:wght@400;500&display=swap',
rel: 'stylesheet',
},
},
{
tag: 'link',
attrs: {
href: 'https://fonts.googleapis.com/css2?family=Google+Symbols&display=block',
rel: 'stylesheet',
},
},
],
plugins: [starlightLinksValidatorPlugin()],
logo: {
dark: './src/assets/lockup_white_tight2.png',
light: './src/assets/lockup_dark_tight.png',
replacesTitle: true,
},
social: [
{
icon: 'github',
label: 'GitHub',
href: 'https://github.com/firebase/genkit',
},
{
icon: 'discord',
label: 'Discord',
href: 'https://discord.gg/qXt5zzQKpc',
},
{
icon: 'x.com',
label: 'X',
href: 'https://x.com/GenkitFramework',
},
{
icon: 'linkedin',
label: 'LinkedIn',
href: 'https://www.linkedin.com/company/genkit',
},
],
sidebar,
customCss: ['./src/tailwind.css'],
editLink: {
baseUrl: 'https://github.com/genkit-ai/docsite/edit/main/',
},
}),
sitemap(),
],
});