Onze · A minimal Eleventy blog template

Translation

Onze is written in English by default, but all user-facing text is configurable through _data/site.json.

Language

Set the lang field to change the site language. This affects the <html lang> attribute and the date formatting:

{
  "lang": "pt-BR"
}

Labels

All UI text comes from the labels field:

{
  "labels": {
    "older": "Anteriores",
    "newer": "Recentes",
    "readMore": "Leia mais",
    "relatedPosts": "Posts Relacionados"
  }
}

Navigation

Navigation items are also in site.json:

{
  "nav": [
    { "label": "Início", "url": "/" },
    { "label": "Sobre", "url": "/about/" }
  ]
}

What changes with lang

  • <html lang="pt-BR"> — helps search engines and screen readers

Date Format

The date format is configurable via the dateFormat field using dayjs patterns:

{
  "dateFormat": "YYYY-MM-DD"
}

Common patterns

Pattern Output
MMMM D, YYYY August 21, 2026 (default)
YYYY-MM-DD 2026-08-21
DD/MM/YYYY 21/08/2026
MMM D, YYYY Aug 21, 2026
D MMMM YYYY 21 August 2026

Translation

Month and day names are automatically translated based on the lang field. The date locale is powered by dayjs. Check the available locales to see supported languages.

No code changes needed. Just edit site.json and your site is translated.