i18n_config/fluent.rs
1use serde::Deserialize;
2use std::path::PathBuf;
3
4/// The data structure representing what is stored (and possible to
5/// store) within the `fluent` subsection of a `i18n.toml` file.
6#[derive(Deserialize, Debug, Clone)]
7pub struct FluentConfig {
8 /// (Required) The path to the assets directory.
9 ///
10 /// The paths inside the assets directory should be structured
11 /// like so: `assets_dir/{language}/{domain}.ftl`
12 pub assets_dir: PathBuf,
13
14 /// (Optional) Domain name to override default value (i.e. package name)
15 /// The paths inside the assets directory should be structured
16 /// like so: `assets_dir/{language}/{domain}.ftl`
17 pub domain: Option<String>,
18}