Approach to retrieve pivot data to represent them or add extra data
Problem
For example having a Post model that morphToMany Tags using a taggleable morph. Pivot data is stored correctly like
{"relation":"tags","properties":[{"taggable_id":23,"taggable_type":"App\\Post","tag_id":3}]}
If need to give user friendly output like tag name, instead of giving just ids, how would you approach this? I tried looking at the parameters recived on supplyExtra but event only includes name not the relationship and properties doesnt have the pivot data. As a model can have a lot of relations and dinamyc morph are harder to deal with when rehidrating, I think this would be a good approach but I dunno how can I access the pivot data.