Hello!
I am pleased to unveil a brand new template
that is the culmination of countless hours of work. The premise behind the initial idea was simple: to have a date on articles with holidays that change dates every year that displays the next occurrence of that holiday and automatically updates once that date has passed.
After a month of testing different methods of approaching this, I decided that it was time to put it into actual template form. The template relies on a custom-built Lua module that will calculate and return the date of a holiday specified by the template. Over time, the scope of the project ballooned and now includes 61distinct holidays, observances, and other such events (at the time of writing), including holidays that people often just don’t remember the date of. Over the past two weeks, I have slowly added it to 680 articles, but this excludes Christmas because 1033 articles have “Christmas” in their titles, so that will be a separate undertaking altogether
The holidays based on the Gregorian calendar (the 12 month calendar we use) were extraordinarily easy to implement. Some holidays rely on entirely different calendars such as the Hebrew lunisolar calendar, the Hijri/Islamic lunar calendar, and the Chinese lunisolar calendar. Because these calendars are completely distinct and separate on how they work, I’ve instead had to implement a table of dates for holidays relying on them for the next 20 years
. I won’t go into the specifics of other troubleshooting, but this project had no shortage of that
Some of my personal favourites from this endeavour include:
- A countdown to the next occurrence of Christmas
- A countdown to the end
of Advent that only appears once Advent has begun
- A dynamic display of the US election cycle. It will automatically tell readers the date of the next election AND if it is a presidential or a midterm election
- Holidays with ranges (i.e. lasting more than one day) will update only after the end date has passed
- Daylight savings time will display the next start and end times for both the Americas and Europe
If you have any requests for holidays I missed, feel free to let me know! The same is true if there are any concerns, issues, etc. I hope you enjoy this as much as I did
13 Likes
Congrats! You’ve been working pretty hard to integrate that, keep it up!
1 Like
This is nice! Im glad you made this.
1 Like
I think this is just fantastic! I’m blown away by the thought and creativity that went into making something so practical and helpful. It’s one of those little things that can really elevate the experience for our readers. Thanks for taking the time to create and implement something so useful!

4 Likes
Wow, this is really something! Its such a helpful little widget. Thank you, @Tiagoroth
!
Happy to help with adding this to the remaining Christmas articles
2 Likes
This is next-level work! Automating dynamic holiday dates especially across different calendars is no small feat. Huge time-saver for so many articles!
1 Like