My Problem right here is that even when my Text is marked as bolt or italic it will not be formated to the standard kirbytext. Also adding the “->kirbytext()” to the echo wont do it (<?php echo $struc['cost']->kirbytext(); ?>)
This is exactly why I prefer the toStructure method when working with structured fields; it allows you to work with the fluent field API as a natural extension instead of having to fall back onto clumsy PHP array constructs and the Kirby helper functions.
True. I’m not denying that there’s uses for yaml() - I’ve had some myself. But in a case like what @Timk describes, where the root of the problem is that yaml() doesn’t give him the field that he’d clearly like to have, I feel somewhat obliged to evangelize for the use of toStructure()