Introduction
php-serialize is a powerful attribute-based PHP serialization library (requires PHP ≥ 8.1). It allows you to map objects to arrays or JSON, and can automatically generate OpenAPI documentation based on the same
🚀 Unified solution supporting API data serialization and document generation.
✨ Features
🏷️ Property alias mapping
🔄 Automatic type conversion
🔁 Support for deep object nesting
❌ Support for skipping/excluding fields
🧩 Recursive DTO (Data Transfer Object) serialization
🧬 Automatically generate OpenAPI schema based on object definitions
⚙️ Framework-agnostic — compatible with Laravel, Symfony, and more
最后更新于