Where to determine

The only documentation I can find about _uihooks added in meteor 0.8.2 is in the helper transition project . Defines _uihooks in the displayed event.

If I define _uihooks in a processed hook, then insertElement _uihook is pretty useless. Since the first time it starts _uihooks does not yet exist, so the first element is not animated.

Of course, I could just put the insertElement animation into the processed hook itself, but why then does insertElement even exist?

So, is there another place where I should define _uihooks? Or should I just ignore the hook in insertElement?

+4
source share
1 answer

_uihooksshould be defined in the immediate parent element that the helper contains {{#each}}, and this is ideally done in the callback .rendered.

Here is how I do it in my application:

https://github.com/mizzao/CrowdMapper/blob/master/client/views/datastream.coffee

+3
source

Source: https://habr.com/ru/post/1545850/


All Articles