psr/clock
PSR-20 Clock interface for PHP. Defines ClockInterface::now() returning DateTimeImmutable, enabling dependency injection of time sources and easy testing. This package provides only the interface; use or create an implementation.
|
Package
|
Description
|
Stars
|
Likes
|
Forks
|
Downloads
|
Issues
|
Score
|
Opportunity
|
License
|
Last Release
|
|
|---|---|---|---|---|---|---|---|---|---|---|---|
| beste/clock | beste/clock is a lightweight PHP clock implementation for time-dependent code. It provides a simple, test-friendly way to obtain the current time, swap in fixed or mock clocks, and improve determinism across your application and automated tests. | 74 | 74 | 1 | 1M | 0 | 22.5 | 65.0 | MIT | 3 years ago | |
| beste/in-memory-cache | PSR-6 compliant in-memory cache for PHP—ideal as a lightweight default cache and for fast, predictable tests. Supports standard CacheItemPoolInterface behavior and optional PSR-20 clocks (e.g., frozen clocks) for time-based expiry testing. | 25 | 25 | 0 | 1M | 0 | 22.0 | 65.0 | MIT | 6 months ago | |
| eventsauce/clock | Simple clock abstraction for PHP. Use SystemClock in production and TestClock in tests to control time deterministically. Get now() as DateTimeImmutable, access timeZone(), move time forward, tick to system time, or fixate to a specific moment. | 3 | 3 | 2 | 38K | 0 | 0.1 | 55.0 | — | — | |
| eventsauce/eventsauce | EventSauce is a PHP event sourcing library for modeling domain events, rebuilding state from event streams, and integrating message dispatching. It provides aggregates, repositories, serializers, and tooling to help implement reliable event-driven architectures. | 6 | — | 1 | — | 1 | 20.2 | — | GPL-2.0 | 10 years ago | |
| kevinrob/guzzle-cache-middleware | RFC 7234-compliant HTTP cache middleware for Guzzle 6+. Add to a HandlerStack to transparently cache responses and speed up API calls. Supports PSR-7 and multiple backends: Laravel Cache, Flysystem, PSR-6/16, and WordPress object cache. | 432 | 435 | 79 | 371K | 20 | 39.6 | 56.2 | MIT | 4 weeks ago | |
| kreait/firebase-php | Unofficial Firebase Admin SDK for PHP. Manage authentication, users, custom tokens, and verify ID tokens; send Cloud Messaging notifications; work with Realtime Database, Cloud Storage, and Remote Config. Built on Google APIs with Laravel-friendly support. | 2,430 | 2,448 | 452 | 1M | 14 | 59.0 | 51.1 | MIT | 1 month ago | |
| laminas/laminas-cache | Laminas Cache provides flexible caching for PHP applications, with adapters for common backends, cache storage, patterns, plugins, and PSR-compatible integrations. Includes tools for configuring, managing, and testing cache behavior in Laminas apps. | 106 | 107 | 58 | 140K | 9 | 34.3 | 56.0 | BSD-3-Clause | 4 weeks ago | |
| laminas/laminas-cache-storage-adapter-memory | In-memory cache storage adapter for Laminas Cache. Provides a simple, fast, non-persistent cache for the current PHP process, useful for testing, prototyping, or per-request caching without external services. | 4 | 4 | 11 | 71K | 1 | 23.9 | 65.0 | BSD-3-Clause | 4 weeks ago | |
| laminas/laminas-cache-storage-adapter-test | Test adapter for Laminas Cache storage. Provides a lightweight in-memory storage implementation useful for unit tests and CI, enabling predictable cache behavior without external services or persistent backends. | 1 | 1 | 10 | 962 | 2 | 27.2 | 44.5 | BSD-3-Clause | 4 weeks ago | |
| lcobucci/clock | PSR-20 clock implementation for PHP. Provides a simple, testable way to access the current time with interchangeable clocks like system and frozen clocks, making time-dependent code predictable and easy to unit test. | 790 | 792 | 32 | 5M | 1 | 30.3 | 61.8 | MIT | 5 months ago | |
| lcobucci/jwt | A lightweight, flexible JWT library for PHP. Create, sign, parse, and validate JSON Web Tokens with support for multiple algorithms, key types, constraints, and claims. Includes a fluent builder, token parser, and robust validation APIs. | 7,479 | 7,558 | 601 | 6M | 6 | 70.7 | 50.0 | BSD-3-Clause | 5 months ago | |
| nesbot/carbon | Carbon is a PHP DateTime extension that makes working with dates and times simple and readable. Parse, format, compare, add/subtract intervals, handle timezones and localization, and use fluent, human-friendly helpers for common date tasks. | 169 | 584 | 26 | 12M | 3 | 27.3 | 66.2 | MIT | 2 days ago | |
| sanmai/duoclock | PSR-20 clock abstraction with dual time access (DateTimeImmutable, time(), microtime()) plus mockable sleep/usleep/nanosleep for testing. Includes deterministic TimeSpy and tick helpers to measure elapsed time. Minimal dependency (psr/clock) and easy to mock. | 3 | 3 | 1 | 768K | 0 | 21.3 | 65.0 | Apache-2.0 | 3 months ago | |
| symfony/clock | Symfony Clock decouples your app from the system clock. Inject ClockInterface to get deterministic time via now() and control behavior like sleep() and time zones. Ideal for testable, time-sensitive code without relying on global time functions. | 430 | 432 | 3 | 10M | 0 | 31.8 | 65.0 | MIT | 1 week ago | |
| web-auth/webauthn-lib | PHP WebAuthn library for adding passkeys/FIDO2 authentication to apps and APIs. Implements registration and login flows, credential validation, and related WebAuthn data structures, suitable for Laravel or custom frameworks. | 119 | 124 | 24 | 484K | 0 | 1.3 | 49.8 | MIT | — | |
| web-token/jwt-library | Read-only sub-repository of the JWT Framework: a PHP JSON Web Token library. For docs and contributions, see the main jwt-framework repo and the official documentation at https://web-token.spomky-labs.com/. MIT licensed. | 20 | 20 | 8 | 990K | 0 | 0.3 | 55.3 | MIT | — | |
| yiisoft/test-support | Testing utilities for Yii applications: helpers and fixtures to simplify unit and integration tests, isolate dependencies, and improve readability. Provides common test tools you can reuse across packages and projects. | 15 | 15 | 9 | 15K | 3 | 22.9 | 48.6 | BSD-3-Clause | 2 months ago |
How can I help you explore Laravel packages today?