XAMPPRocky / fluent-templates

Easily add Fluent to your Rust project.
Apache License 2.0
136 stars 28 forks source link

Some confusion for me #44

Closed jeromeleong closed 1 year ago

jeromeleong commented 1 year ago

I am a beginner in Rust and I want to know how to use a specified FTL file. For example, en-US has main.ftl and other.ftl, but I only want to read the content of other.ftl.

XAMPPRocky commented 1 year ago

Thank you for your issue! In this crate all FTL files of a locale are put into a single bundle, so you always have all the definitions main.ftl and other.ftl available in the loader, there's no way to have only one file available without making it a different locale. Usually you try to keep the message IDs unique in each file as that makes it possible to use tools like Mozilla's Pontoon for message ID tracking.