New

Just launched: Vueblocks, a brand-new search engine for Vue packages! Explore Vueblocks →

racashmoney/laravel-blockable

Trait for Laravel Eloquent models to allow easy implementation of a 'block' or 'ignore' feature.
25 4

Larablocks Analysis

racashmoney/laravel-blockable works with Laravel 5 (latest release 2.0.3, Aug 15, 2016), which reached end of life: no more fixes, even for security.

Laravel 4 in earlier releases.

Recommendation checks

Not advised

Not advised: no release or commit in over 2 years.

  • No release or commit in over 2 years
  • Supports only Laravel 5, past end of life
  • No release in the last 12 months (last: Aug 15, 2016)
  • 0 downloads a month (needs 10,000)
  • 4 GitHub stars (needs 100)

State

Likely abandoned
  • No release or commit in over 2 years.
  • Last stable release: Aug 15, 2016.
  • No releases in the last 12 months.
  • First released: Sep 19, 2014.
  • 0 open issues on GitHub.

Data from Packagist and GitHub, checked by Larablocks on Dec 1, 2026.

Install
composer require racashmoney/laravel-blockable
Latest Version:2.0.3
PHP:>=5.5.0
Laravel:5
Older releases:4
License:MIT
Last Updated:Aug 15, 2016
Links: GitHub  ·  Packagist
Maintainer: racashmoney

Laravel Blockable Plugin

Build Status Latest Stable Version License

Trait for Laravel Eloquent models to allow easy implementation of a "block" or "ignore" feature.

Laravel 5 Documentation

Composer Install (for Laravel 5)
composer require racashmoney/laravel-blockable "~2.0"
Install and then run the migrations
'providers' => [
	\Racashmoney\Blockable\BlockableServiceProvider::class,
],
php artisan vendor:publish --provider="Racashmoney\Blockable\BlockableServiceProvider" --tag=migrations
php artisan migrate
Setup your models
class Article extends \Illuminate\Database\Eloquent\Model {
	use \Racashmoney\Blockable\Blockable;
}
Sample Usage
$article->block(); // block the article for current user
$article->block($myUserId); // pass in your own user id
$article->block(0); // just add blocks to the count, and don't track by user

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

$article->blockCount; // get count of blocks

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

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

Article::whereBlockedBy($myUserId) // find only articles where user blocked them
	->with('blockCounter') // highly suggested to allow eager load
	->get();
Credits

Alternatives to racashmoney/laravel-blockable

cybercog/laravel-ban

Laravel Ban simplify blocking and banning Eloquent models.

823,271 1,120
rtconner/laravel-likeable

Trait for Laravel Eloquent models to allow easy implementation of a 'like' or 'f...

413,644 388

Version History

Version Released PHP Laravel License
2.0.3 >=5.5.0 >=5.0 MIT
2.0.2 >=5.5.0 >=5.0 MIT
2.0.1 >=5.5.0 >=5.0 MIT
2.0.0 >=5.5.0 >=5.0 MIT
1.2.1 >=5.5.0 >=5.0 MIT