rs-i18n
A lightweight and compact I18n library
- author:syf20020816@outlook.com
- createDate:20240106
- updateDate:20240107
- version:0.0.1
- email:syf20020816@outlook.com
QuickStart
1. install dependencies
2. write i18n json file
|
| |
| |
en_US.json
zh_CN.json
3. main.rs
extern crate lazy_static;
use ;
// if use absolute path, you should pay attention that the path should write from root
// means :
// It is an absolute path based on the root directory as the standard
lazy_static!
Use Dev (recommend)
add strum
main.rs
extern crate lazy_static;
use ;
use I18nDict;
lazy_static!
Goals
- translate
- get system lang as default
- dev
- date format