PHPackages                             memran/marwa-support - 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. [Validation &amp; Sanitization](/categories/validation)
4. /
5. memran/marwa-support

ActiveLibrary[Validation &amp; Sanitization](/categories/validation)

memran/marwa-support
====================

Framework-agnostic PHP support library with typed helpers for strings, arrays, files, objects, validation, and security primitives

v1.2.1(1mo ago)01365MITPHPPHP ^8.2CI passing

Since Aug 16Pushed 1mo agoCompare

[ Source](https://github.com/memran/marwa-support)[ Packagist](https://packagist.org/packages/memran/marwa-support)[ RSS](/packages/memran-marwa-support/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (4)Versions (5)Used By (5)

Marwa Support
=============

[](#marwa-support)

[![Latest Version](https://camo.githubusercontent.com/ee349b72c647e08e9d642f4ba1406ece3de8737aa85e49196daa68fbba766805/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d656d72616e2f6d617277612d737570706f72742e737667)](https://packagist.org/packages/memran/marwa-support)[![Total Downloads](https://camo.githubusercontent.com/9fcb08dfc54ff1f3eb8099c5d132dea2f15276a78df04990a784d5169841bfa5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6d656d72616e2f6d617277612d737570706f72742e737667)](https://packagist.org/packages/memran/marwa-support)[![License](https://camo.githubusercontent.com/24940140a08af34fe9fbd644ff21faaef384a11d83e02403db699fdfd1f624cd/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f6d656d72616e2f6d617277612d737570706f72742e737667)](https://packagist.org/packages/memran/marwa-support)[![PHP Version](https://camo.githubusercontent.com/3f669412036e6f91c64a4b5361aeeaa702cbd8cf25a1e1082f474a00f0af7a34/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f6d656d72616e2f6d617277612d737570706f72742e737667)](https://packagist.org/packages/memran/marwa-support)[![CI](https://github.com/memran/marwa-support/actions/workflows/ci.yml/badge.svg)](https://github.com/memran/marwa-support/actions/workflows/ci.yml)[![Coverage](https://camo.githubusercontent.com/292d119717713da21f8d40dad901d09bce0ae32ea4e3c768b3e063d8cfa7f97b/68747470733a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f6769746875622f6d656d72616e2f6d617277612d737570706f72742e737667)](https://codecov.io/gh/memran/marwa-support)[![PHPStan](https://camo.githubusercontent.com/0729e562e10fac943b16dbb271b4af26488f779a33fc82cc3eef1e37a432c0b4/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048505374616e2d6c6576656c253230352d627269676874677265656e2e737667)](https://phpstan.org/)

Framework-agnostic PHP support utilities for common string, array, file, object, validation, HTML, and security tasks. The package is designed for library and application code that needs small, composable helpers with strict typing and predictable behavior.

Requirements
------------

[](#requirements)

- PHP 8.2 or newer
- Extensions: `json`, `mbstring`, `openssl`

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

[](#installation)

```
composer require memran/marwa-support
```

For local development:

```
composer install
```

Usage
-----

[](#usage)

```
use Marwa\Support\Crypt;
use Marwa\Support\File;
use Marwa\Support\Helper;
use Marwa\Support\Str;
use Marwa\Support\Validation;

$slug = Str::slug('Secure Helper Library');
$payload = Crypt::encrypt('secret', $_ENV['APP_KEY']);
File::put(__DIR__ . '/storage/example.json', ['slug' => $slug]);

$validator = Validation::make(
    ['user' => ['email' => 'team@example.com']],
    ['user.email' => 'required|email']
);

if ($validator->fails()) {
    var_dump($validator->errors());
}

$result = Helper::retry(3, fn () => 'ok');
```

Configuration
-------------

[](#configuration)

The library is mostly configuration-free. Pass secrets such as encryption keys from your application configuration or environment, not from hard-coded strings. For CSRF helpers, call them only in applications that already manage PHP sessions safely.

Testing
-------

[](#testing)

```
composer test
composer test:coverage
```

Static Analysis
---------------

[](#static-analysis)

```
composer analyse
composer lint
composer fix
```

`phpstan.neon.dist` runs analysis on `src/` at level 5. `.php-cs-fixer.dist.php` enforces PSR-12-style formatting with strict typing rules.

CI/CD
-----

[](#cicd)

GitHub Actions runs Composer validation, coding standards, PHPStan, and PHPUnit on PHP 8.2, 8.3, and 8.4 through [`.github/workflows/ci.yml`](./.github/workflows/ci.yml).

Contributing
------------

[](#contributing)

1. Install dependencies with `composer install`.
2. Run `composer ci` before opening a pull request.
3. Add or update PHPUnit coverage for behavior changes.
4. Keep commits focused and describe the behavioral impact in the PR.

Repository-specific contributor guidance is available in [`AGENTS.md`](./AGENTS.md).

###  Health Score

44

—

FairBetter than 92% of packages

Maintenance90

Actively maintained with recent releases

Popularity15

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity51

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 ~74 days

Total

4

Last Release

50d ago

PHP version history (2 changes)v1.0.0PHP ^8.0

v1.2.1PHP ^8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/8cf906a31a250a940314fe42f8a18f449647bfe18095457350ff0081cf8dd3c2?d=identicon)[memran](/maintainers/memran)

---

Top Contributors

[![memran](https://avatars.githubusercontent.com/u/7415198?v=4)](https://github.com/memran "memran (12 commits)")

---

Tags

phpvalidationhelperssecurityutilities

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/memran-marwa-support/health.svg)

```
[![Health](https://phpackages.com/badges/memran-marwa-support/health.svg)](https://phpackages.com/packages/memran-marwa-support)
```

###  Alternatives

[progsmile/request-validator

Simple PHP Request Validator

33113.3k1](/packages/progsmile-request-validator)[andreas-glaser/php-helpers

A comprehensive collection of PHP utility functions for array manipulation, string operations, date handling, HTML generation, form building, validation, and more. Modern PHP 8.2+ library with full type safety.

1386.5k2](/packages/andreas-glaser-php-helpers)[event4u/data-helpers

Framework-agnostic PHP library for data mapping, DTOs and utilities. Includes DataMapper, SimpleDto/LiteDto, DataAccessor/Mutator/Filter and helper classes (MathHelper, EnvHelper, etc.). Works with Laravel, Symfony/Doctrine or standalone PHP.

1421.5k](/packages/event4u-data-helpers)

PHPackages © 2026

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