i18n

package
v0.7.13 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 5, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package i18n provides multi-language book support. It parses language definitions from LANGS.md, where each language maps to a subdirectory.

LANGS.md format:

# Languages

* [English](en/)
* [Chinese](zh/)

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LangDef

type LangDef struct {
	Name string // Display name, for example "English".
	Dir  string // Subdirectory path, for example "en" or "zh".
}

LangDef describes one language variant.

func ParseLangsFile

func ParseLangsFile(path string) ([]LangDef, error)

ParseLangsFile parses language definitions from LANGS.md.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL