PHPackages                             marufnwu/laravel-utils - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. marufnwu/laravel-utils

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

marufnwu/laravel-utils
======================

Reusable Laravel utilities including response pipeline, helpers, and common functionality

1.0.2(1y ago)04MITPHPPHP ^7.4|^8.0

Since May 28Pushed 1y agoCompare

[ Source](https://github.com/marufnwu/laravel-utils)[ Packagist](https://packagist.org/packages/marufnwu/laravel-utils)[ Docs](https://github.com/marufnwu/laravel-utils)[ RSS](/packages/marufnwu-laravel-utils/feed)WikiDiscussions main Synced today

READMEChangelogDependencies (10)Versions (4)Used By (0)

Laravel Utils
=============

[](#laravel-utils)

A comprehensive Laravel package providing reusable utilities including response pipeline, array helpers, string helpers, and more.

Features
--------

[](#features)

- 🔄 **Response Pipeline**: Standardized API responses with success/error handling
- 🔧 **Array Helper**: Dot notation access, filtering, grouping, and more
- 📝 **String Helper**: Advanced string manipulation utilities
- 🎨 **Blade Directives**: Custom Blade directives for pipeline responses
- 📦 **Facades**: Easy-to-use facades for all helpers
- 🌍 **Global Helpers**: Optional global helper functions

Installation
------------

[](#installation)

Install via Composer:

```
composer require marufnwu/laravel-utils
```

For Laravel &lt; 11, register the service provider in `config/app.php`:

```
'providers' => [
    // ...
    Marufnwu\Utils\LaravelUtilsServiceProvider::class,
],
```

Publish configuration and resources:

```
php artisan utils:install
```

Quick Start
-----------

[](#quick-start)

### Pipeline Usage

[](#pipeline-usage)

```
use Marufnwu\Utils\Pipeline;

// Success response
return Pipeline::success($data, 'User created successfully')->toApiResponse();

// Error response
return Pipeline::error('Validation failed', 422, $errors)->toApiResponse();

// For views
return Pipeline::success($users)->toViewResponse('users.index');

// For redirects
return Pipeline::success()->toRedirectResponse('dashboard');
```

### Array Helper Usage

[](#array-helper-usage)

```
use Marufnwu\Utils\Helpers\ArrayHelper;

$array = ['user' => ['name' => 'John', 'profile' => ['age' => 25]]];

// Dot notation access
$name = ArrayHelper::get($array, 'user.name'); // 'John'
$age = ArrayHelper::get($array, 'user.profile.age'); // 25

// Set values
ArrayHelper::set($array, 'user.email', 'john@example.com');

// Filter arrays
$users = [
    ['name' => 'John', 'age' => 25],
    ['name' => 'Jane', 'age' => 30],
];
$adults = ArrayHelper::where($users, 'age', '>=', 18);

// Group by key
$grouped = ArrayHelper::groupBy($users, 'age');

// Pluck values
$names = ArrayHelper::pluck($users, 'name'); // ['John', 'Jane']
```

### String Helper Usage

[](#string-helper-usage)

```
use Marufnwu\Utils\Helpers\StringHelper;

// Case conversion
StringHelper::camel('hello_world'); // 'helloWorld'
StringHelper::snake('HelloWorld'); // 'hello_world'
StringHelper::kebab('Hello World'); // 'hello-world'
StringHelper::studly('hello_world'); // 'HelloWorld'

// String manipulation
StringHelper::limit('Long text here...', 10); // 'Long text...'
StringHelper::words('One two three four', 2); // 'One two...'
StringHelper::slug('Hello World!'); // 'hello-world'

// String checks
StringHelper::startsWith('Hello World', 'Hello'); // true
StringHelper::contains('Hello World', 'World'); // true
StringHelper::endsWith('Hello World', 'World'); // true

// Masking
StringHelper::mask('1234567890', '*', 3, 4); // '123****890'
```

### Using Facades

[](#using-facades)

```
use Pipeline;
use ArrayHelper;
use StringHelper;
```

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance47

Moderate activity, may be stable

Popularity3

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity44

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

3

Last Release

402d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/01e3950d529e8f65e0dc0737d79c44ad1ea466dc29664759ad83473f5b3ce4c1?d=identicon)[marufnwu](/maintainers/marufnwu)

---

Top Contributors

[![marufnwu](https://avatars.githubusercontent.com/u/36331934?v=4)](https://github.com/marufnwu "marufnwu (3 commits)")

---

Tags

responselaravelhelpersutilitiespipelinemaruf

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StyleLaravel Pint

Type Coverage Yes

### Embed Badge

![Health badge](/badges/marufnwu-laravel-utils/health.svg)

```
[![Health](https://phpackages.com/badges/marufnwu-laravel-utils/health.svg)](https://phpackages.com/packages/marufnwu-laravel-utils)
```

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M346](/packages/psalm-plugin-laravel)[laravel/cashier

Laravel Cashier provides an expressive, fluent interface to Stripe's subscription billing services.

2.6k29.9M146](/packages/laravel-cashier)[laravel/pulse

Laravel Pulse is a real-time application performance monitoring tool and dashboard for your Laravel application.

1.7k15.1M132](/packages/laravel-pulse)[roots/acorn

Framework for Roots WordPress projects built with Laravel components.

9762.4M131](/packages/roots-acorn)[mike-bronner/laravel-model-caching

Automatic caching for Eloquent models.

2.4k91.0k1](/packages/mike-bronner-laravel-model-caching)[pressbooks/pressbooks

Pressbooks is an open source book publishing tool built on a WordPress multisite platform. Pressbooks outputs books in multiple formats, including PDF, EPUB, web, and a variety of XML flavours, using a theming/templating system, driven by CSS.

45444.2k1](/packages/pressbooks-pressbooks)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
