@@ -0,0 +1,14 @@
|
||||
/**
|
||||
* The locale codes, as plain JavaScript.
|
||||
*
|
||||
* `config.ts` is the real table and everything the site renders reads from it. This
|
||||
* exists because two things run before TypeScript does: `astro.config.mjs`, which needs
|
||||
* the codes to build the i18n config, and the build-time checker. Keeping it to the
|
||||
* bare codes means the duplication is two short arrays that cannot drift far, and
|
||||
* `scripts/check-i18n.mjs` compares the two on every build so they cannot drift at all.
|
||||
*
|
||||
* Adding a language: add the code here and the full entry in `config.ts`.
|
||||
*/
|
||||
export const DEFAULT_LOCALE = 'en';
|
||||
|
||||
export const LOCALE_CODES = ['en', 'es', 'nl'];
|
||||
Reference in New Issue
Block a user