Localization¶
Note
For localization of CMS-based content, see the CMS Localization docs.
We use Project Fluent to localize content that is not in the CMS.
Documentation¶
- Fluent Basics - Writing .ftl files, string IDs, template helpers
- Fluent Configuration - Specifying files, pipeline setup, activation rules
- CSS & Fonts - Locale-specific styles and custom fonts
Quick Reference¶
Use a string id in a template
Check if strings ids are translated
Pass a fallback string id
Reference a variable
# Variables:
# $attrs (string) link to https://example.com
example-read-more = Read more about the <a { $attrs }>example</a>.
{% set attrs='href="https://example.com" rel="external noopener"' %}
<p>{{ ftl('example-read-more', attrs=attrs)}}</p>
Mark a string id obsolete