Skip to content

janakkapadia/commentable

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Laravel Comment Package

Package setup steps:

  • Go to project root directory from terminal

  • Run following commands:

    composer require janakkapadia/commentable
    php artisan vendor:publish --tag=comment-migrations
    php artisan migrate
  • You need add trait in following model:

    use HasComments;
  • Create Comment:

    $model->comments()->create([
        "comment" => "add content here"
    ]);