2 stable releases
1.2.4 | Mar 9, 2023 |
---|---|
1.2.3 | Mar 8, 2023 |
1.1.1 |
|
1.0.0 |
|
0.1.0 |
|
#303 in Internationalization (i18n)
63 downloads per month
Used in rialight
61KB
1K
SLoC
rialight::intl
Internationalization module.
Progress
Use either the Ecma-262 Intl or the ICU4X project for implementing several things.
Not all browsers implement all of Ecma-262 Intl API, or ICU4X doesn't cover all of Intl, so we'll have to support less Intl things for the time being. The goal of this crate is to implement all of Intl. Add more checkboxes for specific features here.
- Currently the
text_direction()
is incorrectly implemented. It compares the language part, not the script part. To fix that,LocaleExpander
fromicu
provides a maximize method, but the constructor requires the data provider. https://github.com/unicode-org/icu4x/issues/3172#issuecomment-1462282871 - Include
icu
data only for non-WebAssembly target. - Learn how to use
js!
macro fromstdweb
. - Collator
- Using
icu
- Using browser-available Ecma-262
Intl
- Using
- DateTimeFormat
- Using
icu
- Using browser-available Ecma-262
Intl
- Using
- DisplayNames
- Using
icu
. Use LanguageDisplayNames and RegionDisplayNames from icu_displaynames - Using browser-available Ecma-262
Intl
- Using
- ListFormat
- Using
icu
- Using browser-available Ecma-262
Intl
- Using
- Locale
- NumberFormat
- Using
icu
- Using browser-available Ecma-262
Intl
- Using
- PluralRules
- Using
icu
- Using browser-available Ecma-262
Intl
- Using
- RelativeTimeFormat
- Using
icu
- Using browser-available Ecma-262
Intl
- Using
- Segmenter
- Using
icu
- Using browser-available Ecma-262
Intl
- Using
FTL Progress
- Arguments
-
arguments!
-
Ftl
- Should the library internally use
fluent::FluentBundle::new_concurrent()
? -
initialize_locale()
- Should the library internally use
ftl.initialize_locale(|locale, bundle| {
// locale: intl::Locale
match locale {
_ => {},
}
});
Dependencies
~17–31MB
~440K SLoC