I18N and Metadata Translations for Data Package
See original GitHub issueHow should the standard support titles, descriptions and data fields in languages other than English?
Proposal (Nov 2016)
An internationalised field:
# i18n
"title": {
"": "Israel's 2015 budget",
"he-IL": "תקציב לשנת 2015",
"es": "Presupuestos Generales del Estado para el año 2015 de Israel"
}
...
Summary:
Each localizable string in datapackage.json could take two forms:
- A simple string (for backward compatibility)
- An object, mapping from ISO Locale codes (with or without the region specification, e.g. ‘en’, or ‘es-ES’) to their representations.
- In this object, you could have an empty key “” which denotes the ‘default’ representation
Not all properties would be localizable for now. For the sake of simplicity, we limit this to only the following properties;
- title (at package and resource level)
- description (at package and resource level)
Default Language
You can define the default language for a data package using a lang
attribute:
"lang": "en"
The default language if none is specified is English (?).
Issue Analytics
- State:
- Created 10 years ago
- Comments:22 (20 by maintainers)
Top Results From Across the Web
Prepare component for translation - Angular
To prepare your project for translation, complete the following actions. ... In a component template, the i18n metadata is the value of the...
Read more >Translations | Metadata API Developer Guide
This metadata type allows you to work with translations for various supported languages. The ability to translate component labels is part of the...
Read more >Preparing a Project to Support Internationalization
These procedures must be performed whether you plan to support only metadata internationalization, only data internationalization, or both.
Read more >Metadata for the Multilingual Web - Usage Scenarios ... - W3C
Create a Translation Package in OASIS XML Localization Interchange ... Load XML, HTML5 and XLIFF content for which ITS 2.0 meta data exists ......
Read more >Localization of DHIS 2 - DHIS2 Documentation
The DHIS 2 Translation app can be used to translate all metadata (data elements, categories, organization units, etc) into any locale which ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
So, I’ve thought quite a bit about this and I generally agree with @akariv approach:
I’ve updated the main description of the issue with a relatively full spec based on this.
Welcome comments from @frictionlessdata/specs-working-group
Research
title@en
. However, this does not seem common and JSON-LD no longer supports this. As @akariv points out it does not necessarily sort well and bloats the top level of the JSON. Also the @ in json property names is kind of annoying.Hi, no news here (only later v1.1)?
If “real life example” is useful to this discussion … My approach (while no v1.1) at datasets-br/state-codes’s
datapackage.json
, was to add lang descriptor and lang-suffix differentiator. Thelang
at source level, as default for all fields.Hum… the interpretation was “language of the descriptions (!and CSV textual contents)”.
If some field or descriptor need to use other language, I use a suffix
-{lang}
. In the example we usedtitle
as default (en) andtitle-pt
for Portuguese title.