PHPackages                             shubhang/laravel-dislikeable - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. shubhang/laravel-dislikeable

ActivePhp[Utility &amp; Helpers](/categories/utility)

shubhang/laravel-dislikeable
============================

Trait for Laravel Eloquent models to allow easy implementation of a 'dislike' feature.

1.0(9y ago)27MITPHPPHP &gt;=5.3.0

Since Jan 9Pushed 8y ago2 watchersCompare

[ Source](https://github.com/shubhang-arora/laravel-dislikable)[ Packagist](https://packagist.org/packages/shubhang/laravel-dislikeable)[ RSS](/packages/shubhang-laravel-dislikeable/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)Dependencies (4)Versions (2)Used By (0)

Laravel DisLikeable Plugin
==========================

[](#laravel-dislikeable-plugin)

Trait for Laravel Eloquent models to allow easy implementation of a "Dislike" feature.

#### Composer Install (for Laravel 5)

[](#composer-install-for-laravel-5)

```
composer require shubhang-arora/laravel-dislikeable "~1.0"

```

#### Install and then run the migrations

[](#install-and-then-run-the-migrations)

```
'providers' => array(
	 Shubhang\DisLikeable\DisLikeableServiceProvider::class,
);
```

```
php artisan vendor:publish --provider="Shubhang\DisLikeable\DisLikeableServiceProvider"
php artisan migrate
```

#### Setup your models

[](#setup-your-models)

```
class Article extends \Illuminate\Database\Eloquent\Model {
	use Shubhang\DisLikeable\DisLikeableTrait;
}

```

#### Sample Usage

[](#sample-usage)

```
$article->dislike(); // dislike the article for current user
$article->dislike($myUserId); // pass in your own user id
$article->dislike(0); // just add dislikes to the count, and don't track by user

$article->undislike(); // remove dislike from the article
$article->undislike($myUserId); // pass in your own user id
$article->undislike(0); // remove dislikes from the count -- does not check for user

$article->dislikeCount; // get count of dislikes

$article->dislikes; // Iterable Illuminate\Database\Eloquent\Collection of existing dislikes

$article->disliked(); // check if currently logged in user disliked the article
$article->disliked($myUserId);

Article::whereDisLiked($myUserId) // find only articles where user disliked them
	->with('dislikeCounter') // highly suggested to allow eager load
	->get();

```

#### Credits

[](#credits)

- Shubhang Arora

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 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

Unknown

Total

1

Last Release

3410d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/d189a57394e5883b452ec2daaf20c1131ea32ba0ca2ab52fb11c376b82c8eee9?d=identicon)[shubhang](/maintainers/shubhang)

---

Top Contributors

[![shubhang-arora](https://avatars.githubusercontent.com/u/12964392?v=4)](https://github.com/shubhang-arora "shubhang-arora (6 commits)")

---

Tags

laravellaravel 5dislikedislikable

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/shubhang-laravel-dislikeable/health.svg)

```
[![Health](https://phpackages.com/badges/shubhang-laravel-dislikeable/health.svg)](https://phpackages.com/packages/shubhang-laravel-dislikeable)
```

###  Alternatives

[barryvdh/laravel-ide-helper

Laravel IDE Helper, generates correct PHPDocs for all Facade classes, to improve auto-completion.

14.9k123.0M687](/packages/barryvdh-laravel-ide-helper)[leantony/laravel-grid

A grid view for laravel, inspired by the yii2 grid widget

9060.2k](/packages/leantony-laravel-grid)[laracraft-tech/laravel-useful-additions

A collection of useful Laravel additions!

58109.4k](/packages/laracraft-tech-laravel-useful-additions)[glhd/special

1929.4k](/packages/glhd-special)[bjuppa/laravel-blog

Add blog functionality to your Laravel project

483.3k2](/packages/bjuppa-laravel-blog)

PHPackages © 2026

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