@rapropos Some time ago you gave me the same answer here: Clickable elements in text
Where it made perfectly sense.
But now I am facing a different situation where this approach turns out as a “problem” for me:
Think about a very modular app which has modules reused in other apps. Since my example would be rather complicated to explain, think about following example which will have the same problem:
Imagine some generic “feed” module (similar a facebook feed) and some other modules which cause “actions” which shall be displayed in the feed. You want to avoid specific implementations for other-module specific actions within the feed module, since it shall be used in several apps.
You now have 2 options:
- Make all the feed items look basically the same (sure you can play with some extra icons, css classes, etc. based on type somehow)
- Support individual feed items per action type. Each action type might require other elements to be displayed, different layouts, extra information and actions for sub-components within the feed entry.
If you can implement case 1, you are lucky. But with case 2 things get complicated. Ideally, you would register the types on the feed module when starting another module, and tell the feed module how to render each action. But without dynamic templates I think this is not posisble.
Unfortunately, I am now on case 2 and melting my brain looking for some generic solution.
So I consider dynamic templating as quite important in some cases. Any further ideas which could help here?