-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implementation of the original functionality of the bundle
- Loading branch information
Showing
14 changed files
with
3,361 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 4 | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/.idea/ | ||
/vendor/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,36 @@ | ||
# symfony-notification-bundle | ||
Bundle for Symfony 4 which helps display information for the user | ||
# Notification Bundle for Symfony 4 | ||
|
||
The Symfony 4 Bundle, which aims to simplify the communication with the end user. | ||
By using simple functions, we can create information that will later be displayed to the user. | ||
|
||
## Installation | ||
|
||
This bundle can be installed by Composer: | ||
|
||
``` | ||
$ composer require m-adamski/symfony-notification-bundle | ||
``` | ||
|
||
## How to use it? | ||
|
||
The helper provides a set of functions with which you can add a notification to the set, create a notification redirection, clear the list of all notifications. | ||
|
||
| Method | Description | | ||
| ------------------------- | ------------------------------------------------------------------------------------------------------------------------------- | | ||
| addNotification | The function adds a notification of a specific type and message content | | ||
| redirectNotification | The function returns a redirection to a specific URL address and adds a notification about certain parameters | | ||
| routeRedirectNotification | Like the redirectNotification function, a redirection to a specific route is returned. Notification is created and added to set | | ||
| clear | The function clears the set of all notifications | | ||
| getNotifications | The function returns a list of all notifications | | ||
|
||
In order for the notifications to be displayed, a reference to the function should be placed in the template. | ||
|
||
```(html) | ||
<section class="breadcrumbs-container"> | ||
{{ notification() }} | ||
</section> | ||
``` | ||
|
||
## License | ||
|
||
MIT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
{ | ||
"name": "m-adamski/symfony-notification-bundle", | ||
"description": "Bundle for Symfony 4 which helps display information for the user", | ||
"type": "symfony-bundle", | ||
"license": "MIT", | ||
"authors": [ | ||
{ | ||
"name": "Maciej Adamski", | ||
"email": "m.adamski@ideacode.pl" | ||
} | ||
], | ||
"require": { | ||
"php": "^7.1", | ||
"symfony/framework-bundle": "^4.1", | ||
"symfony/twig-bundle": "^4.1" | ||
}, | ||
"require-dev": { | ||
"kint-php/kint": "^3.0", | ||
"phpunit/phpunit": "^7.4", | ||
"symfony/phpunit-bridge": "^4.1" | ||
}, | ||
"config": { | ||
"sort-packages": true | ||
}, | ||
"autoload": { | ||
"psr-4": { | ||
"Adamski\\Symfony\\NotificationBundle\\": "src/" | ||
} | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { | ||
"Adamski\\Symfony\\NotificationBundleTests\\": "tests/" | ||
} | ||
}, | ||
"extra": { | ||
"branch-alias": { | ||
"dev-master": "1.0.x-dev" | ||
} | ||
} | ||
} |
Oops, something went wrong.