PHPackages                             hugojf/eflash - 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. hugojf/eflash

ActiveLibrary

hugojf/eflash
=============

Laracasts flash messages wrapper with escaping

v0.2(6y ago)021GPL-3.0-onlyPHPPHP ^7.1CI failing

Since Mar 14Pushed 5y agoCompare

[ Source](https://github.com/HugoJF/eflash)[ Packagist](https://packagist.org/packages/hugojf/eflash)[ Docs](https://github.com/hugojf/eflash)[ RSS](/packages/hugojf-eflash/feed)WikiDiscussions master Synced 4d ago

READMEChangelog (1)Dependencies (4)Versions (3)Used By (0)

Laracasts Flash wrapper for easy HTML escaping
==============================================

[](#laracasts-flash-wrapper-for-easy-html-escaping)

[![Latest Version on Packagist](https://camo.githubusercontent.com/06950c10e1182b69da345bcb9094248e6c0ca0b409a8229f484b34ef2dfc4e88/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6875676f6a662f65666c6173682e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/hugojf/eflash)[![Total Downloads](https://camo.githubusercontent.com/e3ddcf4b71f92b71d1f93cadaf061c2e386a66aa5395732dbd7ba176bf5eceee/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6875676f6a662f65666c6173682e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/hugojf/eflash)

This package wraps `laracasts/flash` in order to help escape HTML special characters with *almost* the same API.

**Facade usage is not implemented since I only use the `flash` helper!**

Why
---

[](#why)

I got tired of this

```
$username = e(auth()->user()->username);

flash()->success("Welcome, $username!");
```

And wanted this

```
eflash()->success('Welcome, %s!', auth()->user()->username);
```

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

[](#installation)

You can install the package via composer:

```
composer require hugojf/eflash
```

Usage
-----

[](#usage)

Usage should be similar to `laracasts/flash` and `sprintf` function.

The first parameter (the template) is **NOT** escaped in order to allow some HTML in the message.

```
eflash()->success($format, ...$args);

eflash()->error($format, ...$args);

eflash()->info($format, ...$args);

eflash()->message($format, $level, ...$args);

eflash()->warning($format, ...$args);
```

Examples
--------

[](#examples)

```
eflash()->success('Welcome %s!', $username);

eflash()->error('Input %s is not valid!', $input);

eflash()->info('Server %s was turned off!', $serverName)->important();

eflash()->message('A boring %s', $message)->overlay();

eflash()->warning('Joined team %s!', $teamName)->overlay();
```

### Testing

[](#testing)

```
composer test
```

### Changelog

[](#changelog)

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

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

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

### Security

[](#security)

If you discover any security related issues, please email [hugo\_jeller@hotmail.com](mailto:hugo_jeller@hotmail.com) instead of using the issue tracker.

Credits
-------

[](#credits)

- [Hugo](https://github.com/hugojf)
- [All Contributors](../../contributors)

License
-------

[](#license)

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

Laravel Package Boilerplate
---------------------------

[](#laravel-package-boilerplate)

This package was generated using the [Laravel Package Boilerplate](https://laravelpackageboilerplate.com).

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity42

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

2

Last Release

2253d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/380670d6a0af4460abf5faeb9fdb4ad87e98bf8d64d4ef41bd1ab1fb7dc28298?d=identicon)[HugoJF](/maintainers/HugoJF)

---

Top Contributors

[![HugoJF](https://avatars.githubusercontent.com/u/1527438?v=4)](https://github.com/HugoJF "HugoJF (6 commits)")

---

Tags

laravellaravel-packagehugojfeflash

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/hugojf-eflash/health.svg)

```
[![Health](https://phpackages.com/badges/hugojf-eflash/health.svg)](https://phpackages.com/packages/hugojf-eflash)
```

###  Alternatives

[fumeapp/modeltyper

Generate TypeScript interfaces from Laravel Models

196277.9k](/packages/fumeapp-modeltyper)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)

PHPackages © 2026

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