All Projects → MauricioRobayo → colombian-holidays

MauricioRobayo / colombian-holidays

Licence: MIT license
Lightweight module to get Colombian holidays for any given year

Programming Languages

typescript
32286 projects
javascript
184084 projects - #8 most used programming language
shell
77523 projects

Projects that are alternatives of or similar to colombian-holidays

new-year-garland
New Year Garland — Новогодняя гирлянда
Stars: ✭ 20 (+25%)
Mutual labels:  holidays
pico-y-placa-medellin
www.picoyplaca.org
Stars: ✭ 14 (-12.5%)
Mutual labels:  colombia
Asistente-LADM-COL
Complemento para QGIS v3 que permite capturar, consultar, mantener, validar y exportar datos conformes con el modelo LADM-COL.
Stars: ✭ 22 (+37.5%)
Mutual labels:  colombia
open hours
Time calculations using business hours
Stars: ✭ 41 (+156.25%)
Mutual labels:  holidays
public-holidays-js
Public holidays by country. Readonly from google calendar. Nodejs module.
Stars: ✭ 18 (+12.5%)
Mutual labels:  holidays
China
🇨🇳 一个轻巧的中国的地区、民族以及节假日信息的查询PHP库
Stars: ✭ 51 (+218.75%)
Mutual labels:  holidays
moment-holiday
A Moment.js plugin for handling holidays. NO LONGER MAINTAINED (DEPRECATED)
Stars: ✭ 82 (+412.5%)
Mutual labels:  holidays
finql
A quantitative finance toolbox
Stars: ✭ 21 (+31.25%)
Mutual labels:  holidays
calendar-holidays
🎄Holidays abstraction for Aeon time management framework
Stars: ✭ 12 (-25%)
Mutual labels:  holidays
holidata
Holidata is the core of holidata.net, a no-nonsense, ad-free provider of international holiday data.
Stars: ✭ 27 (+68.75%)
Mutual labels:  holidays
hebcal-es6
Hebcal, a perpetual Jewish Calendar (ES6)
Stars: ✭ 45 (+181.25%)
Mutual labels:  holidays
timeclock
Simple work time clocking service
Stars: ✭ 21 (+31.25%)
Mutual labels:  holidays
Calendarific
Calendarific holiday sensor for Home Assistant
Stars: ✭ 14 (-12.5%)
Mutual labels:  holidays
BusinessDays.jl
📆 A highly optimized Business Days calculator written in Julia language. Also known as Working Days calculator.
Stars: ✭ 53 (+231.25%)
Mutual labels:  holidays
luxon-business-days
A Luxon plugin for calculating and manipulating business days and holidays.
Stars: ✭ 29 (+81.25%)
Mutual labels:  holidays

Colombian Holidays 🎆

npm version build and release codecov CodeFactor

TypeScript module to calculate colombian holidays for any given year.

Installation

To install as a dependency of your project:

npm install colombian-holidays

Usage

The module exports a single function to get all the holidays for a given year, returning an array with the holidays for the requested year.

The year should be between 1984 and 4099.

CommonJS

const colombianHolidays = require("colombian-holidays").default;

ES6 Modules

import colombianHolidays from "colombian-holidays";

You get a function that you can use to get the complete list of holidays for a given year:

const colombianHolidays2015 = colombianHolidays(2015);

The content of the colombianHolidays2015 variable will be the following array:

[
  { date: '2015-01-01', celebrationDate: '2015-01-01', name: 'Año Nuevo', nextMonday: false },
  { date: '2015-01-06', celebrationDate: '2015-01-12', name: 'Reyes Magos', nextMonday: true },
  { date: '2015-03-19', celebrationDate: '2015-03-23', name: 'San José', nextMonday: true },
  { date: '2015-04-02', celebrationDate: '2015-04-02', name: 'Jueves Santo', nextMonday: false },
  { date: '2015-04-03', celebrationDate: '2015-04-03', name: 'Viernes Santo', nextMonday: false },
  { date: '2015-05-01', celebrationDate: '2015-05-01', name: 'Día del Trabajo', nextMonday: false },
  { date: '2015-05-14', celebrationDate: '2015-05-18', name: 'Ascensión del Señor', nextMonday: true },
  { date: '2015-06-04', celebrationDate: '2015-06-08', name: 'Corpus Christi', nextMonday: true },
  { date: '2015-06-12', celebrationDate: '2015-06-15', name: 'Sagrado Corazón de Jesús', nextMonday: true },
  { date: '2015-06-29', celebrationDate: '2015-06-29', name: 'San Pedro y San Pablo', nextMonday: true },
  { date: '2015-07-20', celebrationDate: '2015-07-20', name: 'Grito de la Independencia', nextMonday: false },
  { date: '2015-08-07', celebrationDate: '2015-08-07', name: 'Batalla de Boyacá', nextMonday: false },
  { date: '2015-08-15', celebrationDate: '2015-08-17', name: 'Asunción de la Virgen', nextMonday: true },
  { date: '2015-10-12', celebrationDate: '2015-10-12', name: 'Día de la Raza', nextMonday: true },
  { date: '2015-11-01', celebrationDate: '2015-11-02', name: 'Todos los Santos', nextMonday: true },
  { date: '2015-11-11', celebrationDate: '2015-11-16', name: 'Independencia de Cartagena', nextMonday: true },
  { date: '2015-12-08', celebrationDate: '2015-12-08', name: 'Inmaculada Concepción', nextMonday: false },
  { date: '2015-12-25', celebrationDate: '2015-12-25', name: 'Navidad', nextMonday: false },
]

If the year is omitted, by default the function will return the holidays for the current year:

const currentYearHolidays = colombianHolidays();

TypeScript

The module is written in TypeScript and type definitions files are included.

Contributing

Contributions, issues and feature requests are welcome!

Show your support

Give a ⭐️ if you like this project!

License

FOSSA Status

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].