-
Notifications
You must be signed in to change notification settings - Fork 1.1k
/
config.ts
349 lines (341 loc) · 12 KB
/
config.ts
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
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
export const SITE = {
title: "Create T3 App",
description: "The best way to start a full-stack, typesafe Next.js app.",
defaultLanguage: "en_US",
};
export const OPEN_GRAPH = {
image: {
src: "images/og-image.png",
alt: "Create T3 App: The best way to start a full-stack, typesafe Next.js app.",
},
twitter: "t3dotgg",
};
// This is the type of the frontmatter you put in the docs markdown files.
export type Frontmatter = {
title: string;
description: string;
layout: string;
image?: { src: string; alt: string };
dir?: "ltr" | "rtl";
ogLocale?: string;
lang?: KnownLanguageCode;
isMdx?: boolean;
};
export const KNOWN_LANGUAGES = {
// Add more languages here
// sv: "Svenska",
ar: "العربية",
en: "English",
fr: "Français",
pt: "Português",
ru: "Русский",
no: "Norsk",
"zh-hans": "简体中文",
tr: "Türkçe",
} as const;
export type KnownLanguageCode = keyof typeof KNOWN_LANGUAGES;
export const GITHUB_EDIT_URL = `https://github.com/t3-oss/create-t3-app/tree/next/www`;
export const COMMUNITY_INVITE_URL = `https://t3.gg/discord`;
// See "Algolia" section of the README for more information.
export const ALGOLIA = {
indexName: "create-t3-app",
appId: "0LE5592BV4",
apiKey: "892c4647b96fe1b3d0b7d8de1c5b5e40",
};
export type OuterHeaders = "Create T3 App" | "Usage" | "Deployment";
export type Sidebar = {
[TCode in KnownLanguageCode]: {
[THeader in OuterHeaders]?: {
text: string;
link: `${TCode}/${string}`;
}[];
};
};
export const SIDEBAR: Sidebar = {
// For Translations:
// Keep the "outer headers" in English so we can match them.
// Translate the "inner headers" to the language you're translating to.
// Omit any files you haven't translated, they'll fallback to English.
// Example:
// sv: {
// "Create T3 App": [
// { text: "Introduktion", link: "sv/introduction" },
// { text: "Installation", link: "sv/installation" },
// ],
// Usage: [{ text: "Miljövariabler", link: "sv/usage/env-variables" }],
// },
ar: {
"Create T3 App": [
{ text: "مُقدمة", link: "ar/introduction" },
{ text: "لماذا CT3A؟", link: "ar/why" },
{ text: "التثبيت", link: "ar/installation" },
{ text: "بِنية المجلد", link: "ar/folder-structure" },
{ text: "أسئلة شائعة", link: "ar/faq" },
{ text: "تطبيقات صُنعت بواسطة T3", link: "ar/t3-collection" },
{ text: "ترشيحات أُخري", link: "ar/other-recs" },
],
Usage: [
{ text: "الخُطوات الأُولي", link: "ar/usage/first-steps" },
{ text: "Next.js", link: "ar/usage/next-js" },
{ text: "TypeScript", link: "ar/usage/typescript" },
{ text: "tRPC", link: "ar/usage/trpc" },
{ text: "Prisma", link: "ar/usage/prisma" },
{ text: "NextAuth.js", link: "ar/usage/next-auth" },
{
text: "Environment Variables",
link: "ar/usage/env-variables",
},
{ text: "Tailwind CSS", link: "ar/usage/tailwind" },
],
Deployment: [
{ text: "Vercel", link: "ar/deployment/vercel" },
{ text: "Docker", link: "ar/deployment/docker" },
],
},
en: {
"Create T3 App": [
{ text: "Introduction", link: "en/introduction" },
{ text: "Why CT3A?", link: "en/why" },
{ text: "Installation", link: "en/installation" },
{ text: "Folder Structure", link: "en/folder-structure" },
{ text: "FAQ", link: "en/faq" },
{ text: "T3 Collection", link: "en/t3-collection" },
{ text: "Other Recommendations", link: "en/other-recs" },
],
Usage: [
{ text: "First Steps", link: "en/usage/first-steps" },
{ text: "Next.js", link: "en/usage/next-js" },
{ text: "TypeScript", link: "en/usage/typescript" },
{ text: "tRPC", link: "en/usage/trpc" },
{ text: "Prisma", link: "en/usage/prisma" },
{ text: "NextAuth.js", link: "en/usage/next-auth" },
{
text: "Environment Variables",
link: "en/usage/env-variables",
},
{ text: "Tailwind CSS", link: "en/usage/tailwind" },
],
Deployment: [
{ text: "Vercel", link: "en/deployment/vercel" },
{ text: "Netlify", link: "en/deployment/netlify" },
{ text: "Docker", link: "en/deployment/docker" },
],
},
fr: {
"Create T3 App": [
{ text: "Introduction", link: "fr/introduction" },
{ text: "Pourquoi CT3A?", link: "fr/why" },
{ text: "Installation", link: "fr/installation" },
{ text: "Structure des dossiers", link: "fr/folder-structure" },
{ text: "FAQ", link: "fr/faq" },
{ text: "Collection T3", link: "fr/t3-collection" },
{ text: "Autres recommandations", link: "fr/other-recs" },
],
Usage: [
{ text: "Premiers pas", link: "fr/usage/first-steps" },
{ text: "Next.js", link: "fr/usage/next-js" },
{ text: "TypeScript", link: "fr/usage/typescript" },
{ text: "tRPC", link: "fr/usage/trpc" },
{ text: "Prisma", link: "fr/usage/prisma" },
{ text: "NextAuth.js", link: "fr/usage/next-auth" },
{
text: "Variables d'environnement",
link: "fr/usage/env-variables",
},
{ text: "Tailwind CSS", link: "fr/usage/tailwind" },
],
Deployment: [
{ text: "Vercel", link: "fr/deployment/vercel" },
{ text: "Netlify", link: "fr/deployment/netlify" },
{ text: "Docker", link: "fr/deployment/docker" },
],
},
pt: {
"Create T3 App": [
{ text: "Introdução", link: "pt/introduction" },
{ text: "Por que o CT3A?", link: "pt/why" },
{ text: "Instalação", link: "pt/installation" },
{ text: "Estrutura de Pastas", link: "pt/folder-structure" },
{ text: "Perguntas Frequentes", link: "pt/faq" },
{ text: "Coleção T3", link: "pt/t3-collection" },
{ text: "Outras Recomendações", link: "pt/other-recs" },
],
Usage: [
{ text: "Primeiros Passos", link: "pt/usage/first-steps" },
{ text: "Next.js", link: "pt/usage/next-js" },
{ text: "TypeScript", link: "pt/usage/typescript" },
{ text: "tRPC", link: "pt/usage/trpc" },
{ text: "Prisma", link: "pt/usage/prisma" },
{ text: "NextAuth.js", link: "pt/usage/next-auth" },
{
text: "Variáveis de Ambiente",
link: "pt/usage/env-variables",
},
{ text: "Tailwind CSS", link: "pt/usage/tailwind" },
],
Deployment: [
{ text: "Vercel", link: "pt/deployment/vercel" },
{ text: "Docker", link: "pt/deployment/docker" },
],
},
ru: {
"Create T3 App": [
{ text: "Введение", link: "ru/introduction" },
{ text: "Почему CT3A?", link: "ru/why" },
{ text: "Установка", link: "ru/installation" },
{ text: "Файловая структура", link: "ru/folder-structure" },
{ text: "FAQ", link: "ru/faq" },
{ text: "T3 коллекция", link: "ru/t3-collection" },
{ text: "Дополнительные рекомендации", link: "ru/other-recs" },
],
Usage: [
{ text: "Первые шаги", link: "ru/usage/first-steps" },
{ text: "Next.js", link: "ru/usage/next-js" },
{ text: "TypeScript", link: "ru/usage/typescript" },
{ text: "tRPC", link: "ru/usage/trpc" },
{ text: "Prisma", link: "ru/usage/prisma" },
{ text: "NextAuth.js", link: "ru/usage/next-auth" },
{
text: "Переменные среды",
link: "ru/usage/env-variables",
},
{ text: "Tailwind CSS", link: "ru/usage/tailwind" },
],
Deployment: [
{ text: "Vercel", link: "ru/deployment/vercel" },
{ text: "Docker", link: "ru/deployment/docker" },
],
},
no: {
"Create T3 App": [
{ text: "Introduksjon", link: "no/introduction" },
{ text: "Hvorfor CT3A?", link: "no/why" },
{ text: "Installasjon", link: "no/installation" },
{ text: "Mappestruktur", link: "no/folder-structure" },
{ text: "FAQ", link: "no/faq" },
{ text: "T3-Kolleksjonen", link: "no/t3-collection" },
{ text: "Andre Anbefalinger", link: "no/other-recs" },
],
Usage: [
{ text: "Første Steg", link: "no/usage/first-steps" },
{ text: "Next.js", link: "no/usage/next-js" },
{ text: "TypeScript", link: "no/usage/typescript" },
{ text: "tRPC", link: "no/usage/trpc" },
{ text: "Prisma", link: "no/usage/prisma" },
{ text: "NextAuth.js", link: "no/usage/next-auth" },
{
text: "Miljøvariabler",
link: "no/usage/env-variables",
},
{ text: "Tailwind CSS", link: "no/usage/tailwind" },
],
Deployment: [
{ text: "Vercel", link: "no/deployment/vercel" },
{ text: "Docker", link: "no/deployment/docker" },
],
},
"zh-hans": {
"Create T3 App": [
{ text: "简介", link: "zh-hans/introduction" },
{ text: "为什么选择 CT3A?", link: "zh-hans/why" },
{ text: "安装", link: "zh-hans/installation" },
{ text: "文件夹结构", link: "zh-hans/folder-structure" },
{ text: "常见疑问", link: "zh-hans/faq" },
{ text: "T3 合集", link: "zh-hans/t3-collection" },
{ text: "其他推荐", link: "zh-hans/other-recs" },
],
Usage: [
{ text: "第一步", link: "zh-hans/usage/first-steps" },
{ text: "Next.js", link: "zh-hans/usage/next-js" },
{ text: "TypeScript", link: "zh-hans/usage/typescript" },
{ text: "tRPC", link: "zh-hans/usage/trpc" },
{ text: "Prisma", link: "zh-hans/usage/prisma" },
{ text: "NextAuth.js", link: "zh-hans/usage/next-auth" },
{
text: "环境变量",
link: "zh-hans/usage/env-variables",
},
{ text: "Tailwind CSS", link: "zh-hans/usage/tailwind" },
],
Deployment: [
{ text: "Vercel", link: "zh-hans/deployment/vercel" },
{ text: "Netlify", link: "zh-hans/deployment/netlify" },
{ text: "Docker", link: "zh-hans/deployment/docker" },
],
},
tr: {
"Create T3 App": [
{ text: "Giriş", link: "tr/introduction" },
{ text: "Neden CT3A?", link: "tr/why" },
{ text: "Kurulum", link: "tr/installation" },
{ text: "Klasör Yapısı", link: "tr/folder-structure" },
{ text: "S. S. S.", link: "tr/faq" },
{ text: "T3 Koleksiyonu", link: "tr/t3-collection" },
{ text: "Diğer Öneriler", link: "tr/other-recs" },
],
Usage: [
{ text: "İlk Adımlar", link: "tr/usage/first-steps" },
{ text: "Next.js", link: "tr/usage/next-js" },
{ text: "TypeScript", link: "tr/usage/typescript" },
{ text: "tRPC", link: "tr/usage/trpc" },
{ text: "Prisma", link: "tr/usage/prisma" },
{ text: "NextAuth.js", link: "tr/usage/next-auth" },
{
text: "Ortam Değişkenleri",
link: "tr/usage/env-variables",
},
{ text: "Tailwind CSS", link: "tr/usage/tailwind" },
],
Deployment: [
{ text: "Vercel", link: "tr/deployment/vercel" },
{ text: "Netlify", link: "tr/deployment/netlify" },
{ text: "Docker", link: "tr/deployment/docker" },
],
},
};
export const SIDEBAR_HEADER_MAP: Record<
Exclude<KnownLanguageCode, "en">,
Record<OuterHeaders, string>
> = {
// Translate the sidebar's "outer headers" here
// sv: {
// "Create T3 App": "Create T3 App",
// Usage: "Användarguide",
// Deployment: "Deployment",
// },
ar: {
"Create T3 App": "Create T3 App",
Usage: "كيفية الإستخدام؟",
Deployment: "نَشر تطبيقك",
},
fr: {
"Create T3 App": "Create T3 App",
Usage: "Utilisation",
Deployment: "Déploiement",
},
pt: {
"Create T3 App": "Create T3 App",
Usage: "Uso",
Deployment: "Deploy",
},
ru: {
"Create T3 App": "Create T3 App",
Usage: "Использование",
Deployment: "Развертывание",
},
no: {
"Create T3 App": "Create T3 App",
Usage: "Bruk",
Deployment: "Utrulling",
},
"zh-hans": {
"Create T3 App": "Create T3 App",
Usage: "用法",
Deployment: "部署",
},
tr: {
"Create T3 App": "Create T3 App",
Usage: "Kullanım",
Deployment: "Dağıtım",
},
};