Skip to content

Latest commit

 

History

History
92 lines (61 loc) · 4.52 KB

README.md

File metadata and controls

92 lines (61 loc) · 4.52 KB

ICU4X Docs Build Status Coverage Status (Coveralls) Coverage Status (Codecov)

Welcome to the home page for the ICU4X project.

ICU4X provides components enabling wide range of software internationalization. It draws deeply from the experience of ICU4C, ICU4J and ECMA-402 and relies on data from the CLDR project.

The design goals of ICU4X are:

  • Small and modular code
  • Pluggable locale data
  • Availability and ease of use in multiple programming languages
  • Written by i18n experts to encourage best practices

Stay informed! Join our public, low-traffic mailing list: [email protected]. Note: After subscribing, check your spam folder for a confirmation.

Documentation

For an introduction to the project, please visit Introduction to ICU4X for Rust tutorial.

For technical information on how to use ICU4X, visit our API docs.

More information about the project can be found in the docs subdirectory.

Quick Start

An example ICU4X powered application in Rust may look like this:

icu = "0.1"
icu_provider_fs = "0.1"
use icu::locid::macros::langid;
use icu::datetime::{DateTimeFormat, date::MockDateTime, options::style};
use icu_provider_fs::FsDataProvider;

fn main() {
    let lid = langid!("ar");

    let date: MockDateTime = "2020-10-14T13:21:00".parse()
        .expect("Failed to parse a date time.");

    let provider = FsDataProvider::try_new("./icu4x-data")
        .expect("Failed to initialize Data Provider.");

    let options = style::Bag {
        time: Some(style::Time::Medium),
        date: Some(style::Date::Long),
        ..Default::default()
    }.into();

    let dtf = DateTimeFormat::try_new(lid, &provider, &options)
        .expect("Failed to initialize Date Time Format");

    let formatted_date = dtf.format(&date);

    println!("📅: {}", formatted_date);
}

Development

ICU4X is developed by the ICU4X-SC. We are a subcommittee of ICU-TC in the Unicode Consortium focused on providing solutions for client-side internationalization. See unicode.org for more information on our governance.

Please subscribe to this repository to participate in discussions. If you want to contribute, see our contributing.md.

Charter

For the full charter, including answers to frequently asked questions, see charter.md.

ICU4X is a new project whose objective is to solve the needs of clients who wish to provide client-side i18n for their products in resource-constrained environments.

ICU4X, or "ICU for X", will be built from the start with several key design constraints:

  1. Small and modular code.
  2. Pluggable locale data.
  3. Availability and ease of use in multiple programming languages.
  4. Written by i18n experts to encourage best practices.

ICU4X will provide an ECMA-402-compatible API surface in the target client-side platforms, including the web platform, iOS, Android, WearOS, WatchOS, Flutter, and Fuchsia, supported in programming languages including Rust, JavaScript, Objective-C, Java, Dart, and C++.

Benchmark dashboards

Component Runtime
locid link
uniset link
fixed_decimal link
plurals link
datetime link