XSD OASIS XLIFF TC · 1.2 (strict)

XLIFF 1.2

XLIFF 1.2 translation file

Translation files exchanged with translators and CAT tools, as used by Xcode, Angular and Symfony.

About

XLIFF 1.2 holds source text and translations unit by unit. Xcode localisation exports, Angular i18n and Symfony translations use it. This is the strict schema, which leaves out elements deprecated in 1.2.

Good to know

  • Tool-specific extensions in other namespaces are accepted as the schema allows. Placeholders inside source and target are not compared.
  • The example is by xmlvalid.com.

Files

2 files · 109.7 KB

The validator loads all of these with their folder structure, so includes and imports resolve as published.

Example document

messages.xlf · 673 B · valid against this schema

In CI and from code

The same schema by its name, xliff-1.2, through the API.

npx @xmlvalid/cli validate "**/*.xml" --schema xliff-1.2
- uses: xmlvalid/validate-action@v1
  with:
    files: "**/*.xml"
    schema: xliff-1.2
    api-key: ${{ secrets.XMLVALID_API_KEY }}
curl https://xmlvalid.com/api/v1/validations \
  -H "Authorization: Bearer $XMLVALID_API_KEY" \
  -F document={{ $schema->example ?? 'document.xml' }} -F schema=xliff-1.2

Free accounts get 100 API validations a month. On Pro, a URL monitor can check a published document against this schema every hour and email you when it breaks. More CI setups