Downloads
Stars
Version
Video Tutorial on YouTube - Click Here
OR
Follow the steps below :
Quick Note: If you are installing this package in a new project, make sure to install the default user authentication system provided with Laravel.
composer require laravel/ui
php artisan ui bootstrap --auth
composer require devsfort/laravel-pigeon-chat
Packages' assets to be published :
The Important assets:
and the optional assets :
to publish the assets, do the following command line with changing the tag value .. that means after --tag=
write devschat-
+ asset name as mentioned above.
Example :
php artisan vendor:publish --tag=devschat-config
config
folder of your Laravel applications and like so with the other asstes (Package's Views, controllers, migrations ...).Migrate the new migrations
that added by the previous step
php artisan migrate
Create a shortcut or a symlink to the storage
folder into the public
folder
php artisan storage:link
For Laravel <=v5.4
that doesn't support package auto-discovery, add the following provider into config/app.php
providers array list :
...
/*
* Package Service Providers...
*/
\DevsFort\Pigeon\Chat\ChatServiceProvider::class,
...
and the following alias into into config/app.php
aliases:
...
/*
* Class Aliases
*/
\'DevsFortChat' =>DevsFort\Pigeon\Chat\Facade\Chat::class,
...
/devschat
, and you can change path name in the config file config/devschat.php
as mentioned in the configurations
below.
You can find and modify the default configurations of the package at config/devschat.php
file that you published in the step 2 of the installation steps .. and all configurations is documented well to be understood by other developers.
This value is the name of the app which is used in the views or elsewhere in the app.
...
'name' => env('DevsFort_NAME', 'Devsfort Messenger'),
...
This value is the path of the package or in other meaning, it is the prefix of all the registered routes in this package.
e.g (yourapp.domain/devschat)
...
'path' => env('DevsFort_PATH', 'devschat'),
...
This value is the middleware of all routes registered in this package which is by default : auth
.
...
'middleware' => env('DevsFort_MIDDLEWARE', 'auth'),
...
This is the user's avatar setting that includes :
...
'user_avatar' => [
'folder' => 'users-avatar',
...
],
...
which is the default folder name to upload and get user's avatar from.
...
'user_avatar' => [
...
'default' => 'avatar.png',
],
...
which is the default avatar file name for users stored in database .. and when you publishing assets
, a copy of the avatar photo will be copied into your storage path.
This array contains the important default values that used in this package :
...
'attachments' => [
'folder' => 'attachments',
...
],
...
This is the default folder name for attachments
in the storage which is all the attachments will be stored in .. and also going to be used in attachments urls in the views.
...
'attachments' => [
...
'route' => 'attachments.download',
],
...
It is the route name of the download attachments
method.
This property if you may need to change the namespace of the route's controllers of this package after publishing the 'controllers' asset, from the default one to your App's controllers namespace.
By default: DevsFort\Pigeon\Chat\Http\Controllers
If published to be modified, it should be like: App\Http\Controllers\vendor\DevsFort
...
'namespace' => env('DevsFort_ROUTES_NAMESPACE', 'DevsFort\Pigeon\Chat\Http\Controllers'),
npm install express socket.io ioredis
server.js
file will be created at public/js/devschat/server.js
node server.js