Hello
It’s confusing. there is a comparison table, but there are still not all relevant helpers described.
The problem is not really to understand what they are doing, thats mostly explained fragmented over the internet, but why they exist and when to use them.
{{partitial}}
Thats the easiest one. Use it to split your handlebars/html files into multiple, but nothing else. Understood.
{{render}} and {{control}}
It looks like {{control}} is the same then {{render}} when a model is specified, I we need {{control}} just when we want the same controller/view rendered without a model multiple times on the same route.
Currently I’m using {{render}} very excessive, because its simple. I use it to encapsulate my staff, like {{render "itemList" items}}
and inside again stuff like {{#each items}}{{render itemListElement this}}{{/each}}
.
I’m not sure if this is the right use for it, but if not, whats the proper use case?
{{control}} is under development, so its not fixed everything yet or documented, and thats cool. But there is still {{render}}.
{{view}}
Renders a View with the current controller. I understood, its very vell documented, but is this usefull for anything? Is there any situation when I should use {{view}} instead of {{render}}? There are the built-in ember form Views like Ember.TextField, but why are they views? It looks more then like components for me.
{{component}}
For me, it looks like a better version of {{view}}. Is this correct? The only abilitiy that it seems to have, is to encapsulate functionality on the Component. Everything else looks similar, just with changed names. So the layouts on views Looks exactly like the wrapping content in components stuff.
So, if we have now {{component}}, why should we use {{view}}, {{control}} or {{render}}? And should I migrate my {{render}} uses to {{component}}?
Soo, are there any good examples, when to use what. Especially for {{render}} {{component}} and {{view}}. Its always clear when I should not use {{view}}, but not in the other direction.
Thanks, Krutius