I am brand new (literally) to Cwicly and was mainly drawn to it due to a need to create a website that relies heavily on Page templates with flexible layouts. I.e. templated pages (not just posts) with dynamic content that may have different arrangements of content.
My thought was to try to use ACF Pro’s flexible content field to achieve this, but now I am wondering if Fragments and template parts can essentially do the same thing - where a Fragment Block is used when assembling a page rather than an ACF Flexible Content block. Would that work?
Can anyone with Cwicly experience comment on this? If I am correct that either approach can work I am curious about the trade offs inherent in each approach.
Or I might be misunderstanding entirely how fragments work, as I have yet to conduct my own experiments.
Great to have you on board, welcome!
At this time, Flexible Content isn’t properly integrated into Cwicly. This is because the templating process requires its own block (rows), much like the repeater.
This is something we have been working on but haven’t finalised yet. Apologies for the inconvenience.
As for Fragments and Template Parts, they can be used in this way, but it depends what content you want to use dynamically, as we won’t be able to access Flexible fields.
Don’t hesitate to give me a few more details if possible.
Thank you @Louis for your quick reply. What I am envisioning is creating ACF fields for Pages (section titles, section header image, section content, etc) and creating ‘mini-templates’ (or you could call them modular ‘components’) such that a Page can be ‘assembled’ by adding these mini-templates as needed, each one pointing to respective ACF fields, in any order the author chose.
ACF Flexible Content lets the Author do this, but as you say, this is not yet integrated into Cwicly. So can this same thing be achieved using the Fragments block?
On further reflection my guess is it would not because the Fragment block would not know which ACF fields to render. If a Page had 2 sections, both using the same Fragment/mini-template, how would its dynamic fields be pointed to the correct data from the Page?