Skip to content

Commit

Permalink
Mention clock interoperability on docs too
Browse files Browse the repository at this point in the history
Signed-off-by: Luís Cobucci <[email protected]>
  • Loading branch information
lcobucci committed Feb 25, 2023
1 parent 3aa05aa commit 47307cc
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 3 deletions.
3 changes: 2 additions & 1 deletion docs/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,8 @@ It configures which are the base constraints to be used during validation.
<?php
declare(strict_types=1);

use Lcobucci\Clock\SystemClock;
use Lcobucci\Clock\SystemClock; // If you prefer, other PSR-20 implementations may also be used
// (https://packagist.org/providers/psr/clock-implementation)
use Lcobucci\JWT\Configuration;
use Lcobucci\JWT\Signer;
use Lcobucci\JWT\Signer\Key\InMemory;
Expand Down
6 changes: 4 additions & 2 deletions docs/quick-start.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@ namespace MyApp;
require 'vendor/autoload.php';

use DateTimeImmutable;
use Lcobucci\Clock\FrozenClock;
use Lcobucci\Clock\FrozenClock; // If you prefer, other PSR-20 implementations may also be used
// (https://packagist.org/providers/psr/clock-implementation)
use Lcobucci\JWT\Builder;
use Lcobucci\JWT\JwtFacade;
use Lcobucci\JWT\Signer\Hmac\Sha256;
Expand Down Expand Up @@ -104,7 +105,8 @@ namespace MyApp;
require 'vendor/autoload.php';

use DateTimeImmutable;
use Lcobucci\Clock\FrozenClock;
use Lcobucci\Clock\FrozenClock; // If you prefer, other PSR-20 implementations may also be used
// (https://packagist.org/providers/psr/clock-implementation)
use Lcobucci\JWT\JwtFacade;
use Lcobucci\JWT\Signer\Hmac\Sha256;
use Lcobucci\JWT\Signer\Key\InMemory;
Expand Down
10 changes: 10 additions & 0 deletions docs/upgrading.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,16 @@ Or:
);
```

### `lcobucci/clock` is not installed by default anymore

Thanks to [PSR-20](https://www.php-fig.org/psr/psr-20/), users can more easily plug-in other [clock implementations](https://packagist.org/providers/psr/clock-implementation) if they choose to do so.

If you like and were already using `lcobucci/clock` on your system, you're required to explicitly add it as a production dependency:

```sh
composer require lcobucci/clock
```

## v3.x to v4.x

The `v4.0.0` aggregates about 5 years of work and contains **several BC-breaks**.
Expand Down

0 comments on commit 47307cc

Please sign in to comment.