We use the subtype metadata field on article to map different content templates in our resolver.
Our newsroom would like a way to automatically select the template based on the field value rather than having to enter each value manually into the resolver. This will allow them to deploy a new template much faster and with less risk of blowing up the resolver configuration.
Example:
We might configure a content mapped template on the subtype field but instead of putting in 2 rows for "foo" and "bar", we would enter one row with a value like {{value}} (anything to indicate to read the article metadatafield value). The newsroom would still have to create and publish the "foo" and "bar" templates.
If there was a subtype value of "biz", and no "biz" template, then a 404 would be appropriate.
Hi John,
We have evalueated this suggestion with the team and decided not to implement because introducing template selection based on dynamic variables (not just article metadata fields) will create more confusion and more error prone than the current model. It will be also making it more difficult to troubleshoot when things don't work as expected.
Thanks for this suggestion! This is an interesting idea that we'd like to explore more. Can you give us any more info about your template creation workflow and the benefits this would provide? If it helps, we recently introduced the ability to edit template names in PageBuilder Editor so you can change those as needed. One concern we have with introducing this functionality would be that renaming a template inadvertently could cause large sections of the site to 404. But we'd like to learn more about this use case and see if this is something we can offer.