https://github.com/andreasnij/a-timer
A simple PHP timer to time/benchmark operations with a short human-readable result.
https://github.com/andreasnij/a-timer
php timer
Last synced: 11 months ago
JSON representation
A simple PHP timer to time/benchmark operations with a short human-readable result.
- Host: GitHub
- URL: https://github.com/andreasnij/a-timer
- Owner: andreasnij
- License: mit
- Created: 2015-11-08T18:21:50.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2024-03-29T13:25:38.000Z (over 2 years ago)
- Last Synced: 2025-08-15T22:04:04.424Z (11 months ago)
- Topics: php, timer
- Language: PHP
- Homepage:
- Size: 15.6 KB
- Stars: 5
- Watchers: 1
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# A Timer
[](https://packagist.org/packages/andreasnij/a-timer)
A simple timer to time/benchmark operations with a short human-readable result.
## Installation
Add the package as a requirement to your `composer.json`:
```bash
$ composer require andreasnij/a-timer
```
## Usage
```php
use ATimer\Timer;
$timer = new Timer();
// Some operations that take time
echo $timer->getDurationFormatted();
// Example output: 1.237s
```
## Author
Andreas Nilsson ()
## License
Licensed under the MIT License - see the [LICENSE](LICENSE.md) file for details.