All files of the content can be written using MD or MDX inside src/content/docs/[lang]
.
Astro can find localized version via the same slug (path to the document) in the another directory:
src/content/docs/[lang]/[slug].md
(or.mdx
)src/content/docs/en/api/effector/clearNode.md
src/content/docs/ru/api/effector/clearNode.md
The most basic setup is in src/consts.ts
.
Translation of the UI elements is in src/languages.ts
.
All navigation structure is in src/navigation.ts
.
Simply install the pnpm
and run:
pnpm install
pnpm start
To fetch commits history, you need Github Personal Access Token. Just add it:
GITHUB_TOKEN=github_pat_REDACTED_TOKEN pnpm start
By default search disabled on the local machine due to index requirements. But you can enable it by following steps:
- Build the docs —
COMPRESS=false pnpm build
- Start search serve server —
pnpm search:dev
- Start astro with env parameter
PUBLIC_SEARCH=true pnpm dev
COMPRESS=false
disables compressing, to speed up build.