PHPackages                             flarone/laravel-favorable - 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. [Database &amp; ORM](/categories/database)
4. /
5. flarone/laravel-favorable

ActiveLibrary[Database &amp; ORM](/categories/database)

flarone/laravel-favorable
=========================

Laravel favorable package to like, dislike and favorite your models

0.0.7(3y ago)1417MITPHPPHP ^7.3|^8.0|^8.1|^8.2

Since Apr 3Pushed 3y agoCompare

[ Source](https://github.com/flarone/laravel-favorable)[ Packagist](https://packagist.org/packages/flarone/laravel-favorable)[ Docs](https://flarone.com)[ RSS](/packages/flarone-laravel-favorable/feed)WikiDiscussions master Synced 3d ago

READMEChangelogDependencies (6)Versions (8)Used By (0)

Laravel Favoriteable
====================

[](#laravel-favoriteable)

Laravel favorable package to like, dislike and favorite your models.

#### Composer Install

[](#composer-install)

```
composer require flarone/laravel-favorable

```

#### Then run the migrations

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

```
php artisan migrate
```

#### Setup your models

[](#setup-your-models)

```
class Article extends \Illuminate\Database\Eloquent\Model {
	use \Flarone\Favoriteable\Favoriteable;
}
```

#### Sample Usage

[](#sample-usage)

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

$model->defavorite(); // remove favorite from the model
$model->defavorite($myUserId); // pass in your own user id
$model->defavorite(0); // remove favorites from the count -- does not check for user

$model->favoriteCount; // get count of favorites

$model->favorites; // Iterable Illuminate\Database\Eloquent\Collection of existing favorites

$model->favorited(); // check if currently logged in user favorited the model
$model->favorited($myUserId);

Model::whereFavoritedBy($myUserId) // find only models where user favorited them
	->with('favoriteCounter') // highly suggested to allow eager load
	->get();
```

#### Extending the favorite model

[](#extending-the-favorite-model)

You can extend the favorite model if needed. To do this create your own Favorite model and let it extend the following favorite base model:

```
\Flarone\Favoriteable\Models\Favorite::class
```

Next, publish the configuration file with the following command:

```
php artisan vendor:publish --provider="Flarone\Favoriteable\FavoriteableServiceProvider" --tag="config"
```

The favorable config file will be copied into your config directory. In this file adjust the `favorite_model` to your own created model.

#### Credits

[](#credits)

- Flarone -

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity56

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

Every ~60 days

Recently: every ~3 days

Total

7

Last Release

1140d ago

PHP version history (2 changes)0.0.1PHP ^7.3|^8.0

0.0.3PHP ^7.3|^8.0|^8.1|^8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/51fd7905d0acba590e8e161f4c10f91eef023650ec78751bb7885ce4e9664df0?d=identicon)[Flarone](/maintainers/Flarone)

---

Top Contributors

[![MarcelWiebenga](https://avatars.githubusercontent.com/u/10196899?v=4)](https://github.com/MarcelWiebenga "MarcelWiebenga (7 commits)")

---

Tags

laraveleloquentlikerememberFollowfavoritelikeablelikablefavouritedislike

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/flarone-laravel-favorable/health.svg)

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

###  Alternatives

[cybercog/laravel-love

Make Laravel Eloquent models reactable with any type of emotions in a minutes!

1.2k302.7k1](/packages/cybercog-laravel-love)[rtconner/laravel-likeable

Trait for Laravel Eloquent models to allow easy implementation of a 'like' or 'favorite' or 'remember' feature.

394388.0k5](/packages/rtconner-laravel-likeable)[qirolab/laravel-reactions

Implement reactions (like, dislike, love, emotion etc) on Laravel Eloquent models.

19564.6k](/packages/qirolab-laravel-reactions)[watson/rememberable

Query caching for Laravel

1.1k5.2M13](/packages/watson-rememberable)[christiankuri/laravel-favorite

Allows Laravel Eloquent models to implement a 'favorite' or 'remember' or 'follow' feature.

226471.2k5](/packages/christiankuri-laravel-favorite)[jamesmills/watchable

A package to allow your Models to become watchable by a User

685.5k](/packages/jamesmills-watchable)

PHPackages © 2026

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