waavi/sanitizer
Waavi Sanitizer provides a simple, flexible way to clean and transform user input in Laravel before validation. Define reusable sanitizers with built-in filters like trim, escape, cast, and custom filters to keep your data safe and consistent.
Architecture fit
SanitizedRequest extending Laravel's FormRequest, plus a standalone Sanitizer service/facade for non-HTTP ingestion.FormRequest::prepareForValidation() has covered roughly the same use case since 5.5. The package is a convenience layer, not a capability layer.Integration feasibility
$filters. A developer can be productive in a day.illuminate/* constraints are the gate; resolution conflicts are likely on Laravel 9+ and on PHP 8.2+ estates.Technical risk
Key questions
prepareForValidation() plus middleware likely suffices.Stack fit
Migration path
prepareForValidation(), or a small internal sanitizer registry. This removes the dependency entirely.Compatibility
composer.lock; add a CI gate that fails if a framework upgrade cannot resolve.Sequencing
prepareForValidation() and compare cost, clarity, and test coverage.Maintenance
Support
Scaling
Failure modes
Ramp-up
FormRequest semantics in hours, and the package adds little novel API surface.Net position: treat this as a stopgap at best. Prefer native prepareForValidation() where the target framework allows; if the specific filter behavior is genuinely required, fork and vendor it with a dated exit tied to the next Laravel upgrade. Do not adopt for new work — the opportunity is small and the lifecycle liability is not.
How can I help you explore Laravel packages today?