Skip to content

Commit

Permalink
Update examples.rst (#1456)
Browse files Browse the repository at this point in the history
Co-authored-by: ~Jhellico <KJhellico@users.noreply.github.com>
Co-authored-by: Arkadii Yakovets <ark@cho.red>
  • Loading branch information
3 people committed Sep 12, 2023
1 parent f239ad5 commit 56f7732
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions docs/source/examples.rst
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,25 @@ fly and the holiday list will be adjusted accordingly:
>> date(2012, 1, 2) in us_holidays
True
Language support
----------------
To change the language translation, you can set the language explicitly.

.. code-block:: python
>>> for dt, name in sorted(holidays.ES(years=2023, language="es").items()):
>>> print(dt, name)
2023-01-06 Epifanía del Señor
2023-04-06 Jueves Santo
2023-04-07 Viernes Santo
2023-05-01 Día del Trabajador
2023-08-15 Asunción de la Virgen
2023-10-12 Día de la Hispanidad
2023-11-01 Todos los Santos
2023-12-06 Día de la Constitución Española
2023-12-08 La Inmaculada Concepción
2023-12-25 Navidad
Date from holiday name
----------------------
Expand Down

0 comments on commit 56f7732

Please sign in to comment.