The source of tifago.com, the website of Tifa. It is a Tifa app: Go serves the pages and the search, and React renders them.
The docs on the site are the docs of Tifa, from one source. go generate ./... reads docs/ of the Tifa version in go.mod, keeps the folders of docs for people who write apps (each is a section of the sidebar), and writes each doc in English and in Chinese into content/docs/, with the changelog in content/site/. Both are generated and committed.
You need Go 1.27, and Node 20.19 or 22.12 and later with pnpm.
| Command | What it does |
|---|---|
pnpm install |
Install the npm packages and write the docs into content/docs/ |
go generate ./... |
Write the docs again, after the Tifa version in go.mod changed |
go tool tifa dev |
Run the site at http://127.0.0.1:9527, rebuilding on every change |
go tool tifa check |
Check the routes, vet and test the Go code, and type-check the TypeScript |
go tool tifa build |
Build the single executable into bin/ |
The site is in English and, under /zh-CN, Chinese. Its words are in app/_locales/, one file per language, and its links and commands in components/site.ts. The pages Why and Examples are Markdown in content/pages/<language>/. The docs are one collection in two languages, content/docs/en-US/ and content/docs/zh-CN/. Both are generated from the docs Tifa ships, the Chinese ones from the .zh-CN.md files beside the English ones. AGENTS.md says how the rest is laid out.
This repository is open source under the MIT license and takes no pull requests, like Tifa. See CONTRIBUTING.md.