Collections withCount() Not Serializing Properly in Livewire

Published on Aug 23, 2021

It seems that hydrating Collections that contain values from withCount() doesn't work properly in Livewire.

The collection items are serialized and unserialized no problems except the dynamic count field does not get restored and inspecting the queries made using Debugbar show that the subquery to get the count does not get executed.

Might have to file an issue in Github for this