🌟 Enhanced Model Serialization in Workflows and Activities
We've revamped the way you handle models within workflows and activities. Taking inspiration from Laravel's SerializesModels trait, we've introduced a new mechanism to make your models more efficient and streamlined during serialization:
- Smart Serialization: Now, instead of passing the entire model to workflows and activities, Laravel Workflow will intelligently serialize just the necessary attributes like the class and ID. This reduces overhead and ensures optimal performance.
- Seamless Restoration: When you retrieve your model in a workflow or activity, Laravel Workflow will automatically restore the full model instance using the serialized data. This ensures you always work with fresh and accurate data.