For example, consider if you have three similar templates, we'll call them Template-Default, Template-Fixed, and Template-Fluid. I want to reuse Template Variables across these but still be able to vary the structure. I can define a property for all my Templates, let's call it
template_alias. For default, I leave this blank. For the fixed and fluid Templates, I give it a value of
-fixed and
-fluid respectively. Then I can use those in my default Template Variable values; consider a Template Variable called
head which I want to vary by Template:
@INHERIT [[$head[[+template_alias]]]]
Now I can inherit the proper head Chunk (I have head, head-fixed, and head-fluid) through an entire node in the MODX tree regardless of which Template the children have assigned to them.