PHPackages                             floor12/yii2-notification - 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. [Mail &amp; Notifications](/categories/mail)
4. /
5. floor12/yii2-notification

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

floor12/yii2-notification
=========================

Simple but useful JS notification script with PHP Api.

1.3.4(3y ago)014.9k↓33.3%15MITJavaScript

Since Jun 27Pushed 3y ago1 watchersCompare

[ Source](https://github.com/floor12/yii2-notification)[ Packagist](https://packagist.org/packages/floor12/yii2-notification)[ RSS](/packages/floor12-yii2-notification/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (1)Versions (10)Used By (5)

yii2-notification
=================

[](#yii2-notification)

[![Latest Stable Version](https://camo.githubusercontent.com/bba27b91ab747a49ea062c7dd0db9f58c948a35038b1869dc7f4397afb32085c/68747470733a2f2f706f7365722e707567782e6f72672f666c6f6f7231322f796969322d6e6f74696669636174696f6e2f762f737461626c65)](https://packagist.org/packages/floor12/yii2-notification)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/8af0bb8739c2c336a2f131d58311115a5ee5a82cd0bea60ab5903d24d41b8317/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f666c6f6f7231322f796969322d6e6f74696669636174696f6e2f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/floor12/yii2-notification/?branch=master)[![Latest Unstable Version](https://camo.githubusercontent.com/f8c355582ec7ca133b552fdf877e0a2dafff079f4911149eb427576038e3fd34/68747470733a2f2f706f7365722e707567782e6f72672f666c6f6f7231322f796969322d6e6f74696669636174696f6e2f762f756e737461626c65)](https://packagist.org/packages/floor12/yii2-notification)[![Total Downloads](https://camo.githubusercontent.com/3875e7672bf4686f6bcaacf9e538b2a84783e2d57b3d5bb407aca1c6459133d7/68747470733a2f2f706f7365722e707567782e6f72672f666c6f6f7231322f796969322d6e6f74696669636174696f6e2f646f776e6c6f616473)](https://packagist.org/packages/floor12/yii2-notification)[![License](https://camo.githubusercontent.com/03a5d3cd6db40881635e19782dd0ac2b93e751984e65f1ed2976aec3bd2dab4f/68747470733a2f2f706f7365722e707567782e6f72672f666c6f6f7231322f796969322d6e6f74696669636174696f6e2f6c6963656e7365)](https://packagist.org/packages/floor12/yii2-notification)

*Этот файл так же доступен на [русском языке](README_RUS.md).*

This simple extension helps to show nice notifications in browser. It use svg icons and can be customised by overwriting base CSS styles.

[![Image](notification.jpg)](notification.jpg)

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

[](#installation)

Just run:

```
$ composer require floor12/yii2-notification
```

or add this to the require section of your composer.json.

```
"floor12/yii2-notification": "dev-master"
```

To include js and css files, add `floor12\notification\NotificationAsset` as dependency in your AppAsset:

```
use floor12\notification\NotificationAsset;
use yii\web\AssetBundle;

class AppAsset extends AssetBundle
{
    ...
    public $depends = [
        NotificationAsset::class
    ];
}
```

Using as JS
-----------

[](#using-as-js)

To show notification in browser just pass message text to one of the `f12notification` object methods:

```
f12notification.info(text);    //information message;
f12notification.success(text); //success message;
f12notification.error(text);   //error message;
```

For example:

```
if (userSucces == true)
  f12notification.success('Registration success'.)
else
  f12notification.error('Registration failed.')
```

Using as PHP
------------

[](#using-as-php)

Its also possible to show notifications by passing message text to one of the `floor12\notification\Notification` methods:

```
use floor12\notification\Notification;

Notification::info('The form is loading...');
Notification::error('Pleas fill all required fields');
Notification::success('This model is saved');
```

In case if using PHP api, `NotificationAsset` will be included in your app by `Notification` class.

###  Health Score

35

—

LowBetter than 80% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity24

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity68

Established project with proven stability

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

Recently: every ~288 days

Total

9

Last Release

1228d ago

Major Versions

v0.1.0 → 1.0.02018-07-03

### Community

Maintainers

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

---

Top Contributors

[![floor12](https://avatars.githubusercontent.com/u/8406969?v=4)](https://github.com/floor12 "floor12 (20 commits)")

---

Tags

notificationnotify

### Embed Badge

![Health badge](/badges/floor12-yii2-notification/health.svg)

```
[![Health](https://phpackages.com/badges/floor12-yii2-notification/health.svg)](https://phpackages.com/packages/floor12-yii2-notification)
```

###  Alternatives

[mouse0270/bootstrap-growl

This is a simple pluging that turns standard Bootstrap alerts into "Growl-like" notifications.

2.2k119.1k](/packages/mouse0270-bootstrap-growl)[guanguans/notify

Push notification SDK(AnPush、Bark、Chanify、DingTalk、Discord、Gitter、GoogleChat、IGot、Lark、Mattermost、MicrosoftTeams、NowPush、Ntfy、Push、Pushback、PushBullet、PushDeer、PushMe、Pushover、PushPlus、QQ、RocketChat、ServerChan、ShowdocPush、SimplePush、Slack、Telegram、WeWork、WPush、XiZhi、YiFengChuanHua、ZohoCliq、ZohoCliqWebHook、Zulip).

682104.9k7](/packages/guanguans-notify)[machour/yii2-notifications

Notifications for your Yii2 app

9135.7k](/packages/machour-yii2-notifications)[loveorigami/yii2-notification-wrapper

This module for renders a message from session flash (with ajax, pjax support and etc.)

77199.7k5](/packages/loveorigami-yii2-notification-wrapper)[helmesvs/laravel-notify

Elegant notifications to laravel with Toastr or PNotify

6127.3k](/packages/helmesvs-laravel-notify)[sarfraznawaz2005/noty

Laravel package to incorporate noty flash notifications into laravel.

324.4k](/packages/sarfraznawaz2005-noty)

PHPackages © 2026

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