DEV Community

Sarfraz Ahmed
Sarfraz Ahmed

Posted on • Edited on

1

Laravel Noty

Laravel package to incorporate beautiful noty notifications into laravel as flash messages.

GitHub logo sarfraznawaz2005 / noty

Laravel package to incorporate beautiful noty notifications into laravel as flash messages.

Latest Version on Packagist Total Downloads

Laravel Noty

Laravel package to incorporate beautiful noty notifications into laravel as flash messages.

Tested with version 3.2.0 of noty.

Screenshot

Main Window

Requirements

  • PHP >= 5.6
  • Laravel 5
  • noty

Installation

Via Composer

$ composer require sarfraznawaz2005/noty
Enter fullscreen mode Exit fullscreen mode

For Laravel < 5.5:

Add Service Provider to config/app.php in providers section

Sarfraznawaz2005\Noty\NotyServiceProvider::class,
Enter fullscreen mode Exit fullscreen mode

Publish package's config file by running below command:

$ php artisan vendor:publish --provider="Sarfraznawaz2005\Noty\NotyServiceProvider"
Enter fullscreen mode Exit fullscreen mode

It should publish config/noty.php config file.

Setup Noty

Before using this package, make sure you include noty library into your project either by using npm/yarn/etc or directly including its css and js files:

<head>
    <link rel="stylesheet" href="/noty.css"/&gt
    <script type="text/javascript" src="/noty.js"></script>
</head>
Enter fullscreen mode Exit fullscreen mode

and then add this in your view/layout file:

@include('noty::view')
Enter fullscreen mode Exit fullscreen mode

Usage

Syntax:

noty(
Enter fullscreen mode Exit fullscreen mode

Top comments (3)

Collapse
 
sarfraznawaz2005 profile image
Sarfraz Ahmed

I can never understand how to write post, content never shows up. Here is the link anyways:

github.com/sarfraznawaz2005/noty

Collapse
 
jess profile image
Jess Lee

Hi Sarfraz,

The post body can go under the front matter (below ---). The description is a summary of the article.

You can also embed your github repo with this syntax:

{% github https://github.com/sarfraznawaz2005/noty %}

Here's our editor guide with more information: dev.to/p/editor_guide

Collapse
 
sarfraznawaz2005 profile image
Sarfraz Ahmed

Thanks Lee :)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Discover a treasure trove of wisdom within this insightful piece, highly respected in the nurturing DEV Community enviroment. Developers, whether novice or expert, are encouraged to participate and add to our shared knowledge basin.

A simple "thank you" can illuminate someone's day. Express your appreciation in the comments section!

On DEV, sharing ideas smoothens our journey and strengthens our community ties. Learn something useful? Offering a quick thanks to the author is deeply appreciated.

Okay