An open API service indexing awesome lists of open source software.

https://github.com/poldixd/human-readable-time

This package shows date time or human readable time. You can adjust the exact time when the package shows the date time instead the human readable time.
https://github.com/poldixd/human-readable-time

blade carbon datetime laravel time

Last synced: 10 months ago
JSON representation

This package shows date time or human readable time. You can adjust the exact time when the package shows the date time instead the human readable time.

Awesome Lists containing this project

README

          

# Show date time or human readable time 🕐 👀

This package shows date time or human readable time. You can adjust the exact time when the package shows the date time instead the human readable time.

Human readable time example:

```php
$datetime = \Carbon\Carbon::parse('2021-05-05 10:30:00')->subMinutes(15);

```

Output:

```html


```

Date time example:

```php
$datetime = \Carbon\Carbon::parse('2021-05-05 10:30:00')->subMinutes(90);

```

Output:

```html


```

You can adjust the time when the date time is displayed. The default time is 1 hour.

```php
$datetime = \Carbon\Carbon::parse('2021-05-05 10:30:00')->subMinutes(120);

```

Output:

```html


```

## Requirements

- Laravel 9.x or Laravel 10.x
- PHP 8.x

## Installation

You can install the package via composer:

```bash
composer require poldixd/human-readable-time
```

## Testing

```bash
composer test
```

## Changelog

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

## Credits

- [Nils Poltmann](https://github.com/poldixd)
- [All Contributors](../../contributors)

## License

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.