12 releases
0.1.11 | Jul 30, 2024 |
---|---|
0.1.10 | Mar 26, 2024 |
0.1.9 | Oct 5, 2023 |
0.1.8 | Oct 14, 2022 |
0.1.3 | Nov 20, 2021 |
#35 in Internationalization (i18n)
11,532 downloads per month
Used in 26 crates
(2 directly)
750KB
2.5K
SLoC
precis-profiles
PRECIS Framework: Preparation, Enforcement, and Comparison of Internationalized Strings in Application Protocols as described in rfc8264
This crate implements the next PRECIS profiles:
- rfc8265. Preparation, Enforcement, and Comparison of Internationalized Strings Representing Usernames and Passwords.
- rfc8266. Preparation, Enforcement, and Comparison of Internationalized Strings Representing Nicknames
Examples
assert_eq!(Nickname::prepare("Guybrush Threepwood"),
Ok(Cow::from("Guybrush Threepwood")));
assert_eq!(Nickname::enforce(" Guybrush Threepwood "),
Ok(Cow::from("Guybrush Threepwood")));
assert_eq!(Nickname::compare("Guybrush Threepwood ",
"guybrush threepwood"), Ok(true));
Contributing
Patches and feedback are welcome.
Donations
If you find this project helpful, you may consider making a donation:
License
This project is licensed under either of
Dependencies
~0.9–2.4MB
~50K SLoC