Documentation ¶
Overview ¶
Package locales 为 web 包提供了本地化的内容
Index ¶
Constants ¶
View Source
const ( ShouldGreatThanZero = localeutil.StringPhrase("should great than 0") InvalidValue = localeutil.StringPhrase("invalid value") CanNotBeEmpty = localeutil.StringPhrase("can not be empty") DuplicateValue = localeutil.StringPhrase("duplicate value") UniqueIdentityGenerator = localeutil.StringPhrase("unique identity generator") RecycleLocalCache = localeutil.StringPhrase("recycle local cache") )
一些多处用到的翻译项
Variables ¶
All 当前框架依赖的所有本地化内容
文件格式均为 yaml,使用时加载这些文件系统下的 yaml 文件即可:
s := web.NewServer(...) s.LoadLocale("*.yaml", locales.All()...)
View Source
var Locales embed.FS
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.