rokde/laravel-utilities

Some laravel or php related utilities.

Installs: 62

Dependents: 1

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Open Issues: 1

pkg:composer/rokde/laravel-utilities

1.0.1 2024-02-06 16:03 UTC

This package is auto-updated.

Last update: 2025-10-13 07:25:29 UTC


README

Latest Version on Packagist GitHub Tests Action Status GitHub Code Style Action Status Total Downloads

Some laravel or php related utilities.

composer require rokde/laravel-utilities

Stopwatch

A simple stopwatch to measure the time between operations.

use Rokde\LaravelUtilities\Utilities\Stopwatch;

$stopwatch = Stopwatch::make();

echo $stopwatch->measure();
// do a long running task
echo $stopwatch->measure();

// displays
// 00:00:00.034240
// 00:00:03.078050

Memory

Simple memory service to get peak and usage formatted.

echo '[' . Memory::usage() . ' / ' . Memory::peak() . ']';

// displays
// [8.31 MB / 8.96 MB]