tsantos/serializer
A PHP serialization library for Laravel projects that converts objects to arrays and JSON using configurable metadata, with support for custom handlers, relationships, and versioned API output.
Consider it only as a reference or fork candidate, and only when:
Look elsewhere when:
symfony/serializer with symfony/property-info and warmup/caching, or spatie/laravel-data if you want Laravel-native DTOs with good DX.For executives: This is a niche, unmaintained PHP serialization library with negligible adoption (28 stars, zero dependents, no release since 2018). We should not add it as a production dependency. However, its approach — generating serializer code at build time instead of reflecting at runtime — is a legitimate lever if serialization ever shows up as a measurable API latency cost. Recommendation: treat it as an architectural reference, not a vendor selection.
For engineering: Valuable as a design pattern study (compiled serializers, cached artifacts, minimal runtime reflection) and as a fork candidate only if we hit a proven bottleneck with stable DTO shapes. Default position: standardize on a maintained serializer behind our own Serializer interface so the implementation stays swappable; benchmark before optimizing. If we ever build an in-house generated-serializer layer, this repo is a useful prior-art input and a cost-estimation anchor.
Bottom line for the roadmap: No action this quarter. Log the "compiled serialization" pattern against the API-performance epic as a contingency, and re-evaluate only when profiling justifies it.
How can I help you explore Laravel packages today?