https://github.com/navarr/wall-clock
PSR-20 implementation of a Wall (System) Clock
https://github.com/navarr/wall-clock
Last synced: 23 days ago
JSON representation
PSR-20 implementation of a Wall (System) Clock
- Host: GitHub
- URL: https://github.com/navarr/wall-clock
- Owner: navarr
- License: mit
- Created: 2021-08-29T20:02:33.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2024-01-11T13:52:39.000Z (over 2 years ago)
- Last Synced: 2025-07-03T11:04:33.726Z (about 1 year ago)
- Language: PHP
- Size: 17.6 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Wall Clock (PSR-20)
[](https://packagist.org/packages/navarr/wall-clock)
[](https://packagist.org/packages/navarr/wall-clock)
[](https://packagist.org/packages/navarr/wall-clock)
[](https://packagist.org/packages/navarr/wall-clock)


[](https://dashboard.stryker-mutator.io/reports/github.com/navarr/wall-clock/main)
This library contains an implementation of PSR-20 that provides a new DateTimeImmutable instance everytime its called
## Installation
composer require navarr/wall-clock:^1
## Usage
```php
use Navarr\WallClock\WallClock;
$clock = new WallClock();
$clock->now()->format('Y-m-d H:i:s') === date('Y-m-d H:i:s')
```