PHPackages                             statix-php/laravel-form-actions - 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. statix-php/laravel-form-actions

ActiveLibrary

statix-php/laravel-form-actions
===============================

Form Requests mixed with Actions for Laravel

0.0.3(2y ago)010[3 PRs](https://github.com/statix-php/laravel-form-actions/pulls)MITPHPPHP ^8.1CI passing

Since Sep 2Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/statix-php/laravel-form-actions)[ Packagist](https://packagist.org/packages/statix-php/laravel-form-actions)[ Docs](https://github.com/statix-php/laravel-form-actions)[ RSS](/packages/statix-php-laravel-form-actions/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)Dependencies (12)Versions (8)Used By (0)

Laravel Form Actions
====================

[](#laravel-form-actions)

[![Latest Version on Packagist](https://camo.githubusercontent.com/c8b6f874a34bb13a2fab7905dba49a2d55cc8e953998ff9a3c3448d524da55cb/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7374617469782d7068702f6c61726176656c2d666f726d2d616374696f6e732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/statix-php/laravel-form-actions)[![Total Downloads](https://camo.githubusercontent.com/e115c38fddc0b1a37c5c7851ffaa0b14d33a1e8ea72d4485ac9518bc01afe07e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7374617469782d7068702f6c61726176656c2d666f726d2d616374696f6e732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/statix-php/laravel-form-actions)

Laravel Form Actions combines the best features of Spatie's Laravel Data and Laravel's Form Requests, resulting in a powerful and efficient package that simplifies form handling in your Laravel applications.

Installation
------------

[](#installation)

You can easily install this package using Composer by running the following command. For more details, visit the [Packagist page](https://packagist.org/packages/statix-php/laravel-form-actions).

```
composer require statix-php/laravel-form-actions
```

Creating `FormActions`
----------------------

[](#creating-formactions)

Similiar to [Laravel Form Requests](https://laravel.com/docs/validation#form-request-validation), you can create a new `FormAction` using Artisan with the following command:

```
php artisan make:form-action ActionName
```

This command will generate a ActionName class in the app\\Actions directory. The initial content of the class is as follows:

```
