dees040/persisting-requests
Larablocks Analysis
dees040/persisting-requests works with Laravel 5 (latest release 0.1.1, Oct 6, 2017), which reached end of life: no more fixes, even for security.
Recommendation checks
Not advisedNot 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: Oct 6, 2017)
- 0 downloads a month (needs 10,000)
- 0 GitHub stars (needs 100)
State
Likely abandoned- No release or commit in over 2 years.
- Last stable release: Oct 6, 2017.
- No releases in the last 12 months.
- First released: Apr 22, 2017.
- 0 open issues on GitHub.
Data from Packagist and GitHub, checked by Larablocks on Dec 1, 2026.
| Install | |
|---|---|
composer require dees040/persisting-requests |
|
| Latest Version: | 0.1.1 |
| PHP: | >=5.4.0 |
| Laravel: | 5 |
| License: | Beerware |
| Last Updated: | Oct 6, 2017 |
| Links: | GitHub · Packagist |
Persisting Requests
This package will let you create persisting requests in a breeze. It will call a persisting method on your request via the Laravel Container, meaning you can use dependency injection. The package is inspired by this Laracasts video. The package can help cleaning up your controller.
Installation
Install the latest version with composer.
composer require dees040/persisting-request
After installing the packages and the service provider to the providers array in app/config.php.
dees040\PersistingRequests\ServiceProvider::class,
Usage
You can now run the make:persist command.
php artisan make:persist FooBarRequest
In your controller you can now add the fresh created request to the method. Laravel will automatically inject in via dependency injection.
<?php
namespace App\Http\Controllers;
use App\Http\Requests\FooBarRequest;
class ActivationController extends Controller
{
public function activate(FooBarRequest $request)
{
$request->persist();
return view('home');
}
}
Now in your request you can add dependencies to the persisting method.
<?php
namespace App\Http\Requests;
use dees040\PersistingRequests\PersistingRequest;
class FooBarRequest extends PersistingRequest
{
/**
* Persist the request.
*
* @return void
*/
public function persisting(ActivationManager $manager)
{
$manager->activate($this->user());
}
}
Related Packages
A Streams Platform plugin that provides API access to Laravel's Request class.
Version History
| Version | Released | PHP | Laravel | License |
|---|---|---|---|---|
| 0.1.1 | >=5.4.0 | 5.0.x| | Beerware | |
| 0.1 | >=5.4.0 | ^5.0,<5.5 | Beerware |