> ## Documentation Index
> Fetch the complete documentation index at: https://docs.reelevant.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Format Date (Variable Locale)

> Formater une date avec la locale provenant d'une variable

## Présentation

La transformation `format-date-locale-var` formate une valeur de date en utilisant une locale fournie sous forme de variable. Elle est similaire à [Format Date](/fr/advanced-guide/transformations/format-date), mais la locale de sortie provient d'une variable au lieu d'une option statique.

## Syntaxe

```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
format-date-locale-var(<variable>, <locale-variable>, format="DATE_SHORT")
```

## Paramètres

| Paramètre         | Type     | Requis | Description                                                                                                                   |
| ----------------- | -------- | ------ | ----------------------------------------------------------------------------------------------------------------------------- |
| `variable`        | date     | Oui    | La valeur de date à formater                                                                                                  |
| `locale-variable` | variable | Oui    | La variable de locale (par ex. `"en-US"`, `"fr-FR"`)                                                                          |
| `format`          | string   | Oui    | La clé de format prédéfinie (voir [Format Date](/fr/advanced-guide/transformations/format-date) pour les formats disponibles) |
| `timezone`        | string   | Non    | Le fuseau horaire à utiliser (par ex. `"UTC"`, `"Europe/Paris"`). Par défaut `"UTC"`                                          |
| `inputLocale`     | string   | Non    | Locale utilisée pour analyser la date d'entrée : `"pt"`, `"nl"`, `"en"`, `"de"`, `"ja"`, `"zh"` ou `"fr"`                     |

## Exemples

```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
format-date-locale-var(<variable>, <locale-variable>, format="DATE_SHORT")
format-date-locale-var(<variable>, <locale-variable>, format="DATETIME", timezone="Europe/Paris")
```
