hermajan / timely
A collection of time, date, calendar utilities, Easter calculation algorithms, Czech name days, and alternative clock implementations in PHP and JavaScript.
Requires
- php: >=7.1
- ext-json: *
Requires (Dev)
- phpunit/phpunit: ^7.5 || ^8.5 || ^9.6
Suggests
- ext-calendar: Faster calculation of Easter Sunday, otherwise a ported algorithm is used
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-10-19 22:45:41 UTC
README
A collection of time, date, calendar utilities, Easter calculation algorithms, Czech name days, and alternative clock implementations.
✨ Features
- Dates: date comparison and working days in PHP, Gregorian and Julian conversions in Java, day of the week and date formatting in JavaScript.
- Easter: Easter Sunday by Butcher, Oudin and Meeus algorithms, plus Good Friday and Easter Monday.
- Holidays: Czech and Slovak public holidays from JSON data files in PHP.
- Name Days: Czech and Slovak name days lookup in Java, JavaScript and PHP.
- Times: current date and time formatting in PHP.
- Years: leap year checks in Java, JavaScript and PHP.
- Clocks: alternative and interactive clocks (BCD, binary, normal, verbal in Czech and English, hexcolor).
- Examples: browser demos of the JavaScript classes in the
examples/folder.
📋 Requirements
Everything below is optional. Install only what you need for the language you use.
| Language | Requirement | Used for |
|---|---|---|
| Java | JDK 17 or newer | *.java sources and tests (bin/java-tests.*) |
| JavaScript | Node.js 14 or newer and npm | *.js sources and tests (npm test) |
| PHP | PHP 7.1 or newer, Composer, or Docker | *.php sources and tests (bin/php-tests.*) |
| Dart | Dart SDK | Recompiling *.dart sources into *.js |
| Browser | Any modern browser | *.html pages, served over HTTP |
Maven is not required for Java: the test scripts use the mvn on your PATH or download Maven 3.9.9 into ~/.maven if it is missing. JUnit 4 is fetched by Maven.
PHP tests use PHPUnit (phpunit.xml). bin/php-tests.* runs them in a Docker image with PHP 7.1 and Composer (bin/php.Dockerfile), so only Docker is required, not PHP. With PHP and Composer installed you can also run composer install and composer test:php.
📚 Documentation
Detailed project documentation is available in the wiki.