# @for control-flow block

I think the track argument is not described transparently enough in the official Angular documentation and I had a few questions about it that remained unanswered.

In the following article I tried to show you how the track-expression can be written.

### Decision maker:

* **$index** -&gt; if collection doesn't change ( `@for(todo of todos; track $index) {}` )
    
* **unique id** -&gt; if collection changes ( `@for(todo of todos; track todo.id) {}` )
    
* **object reference** -&gt; if collection changes and no unique id ( `@for(todo of todos; track todo) {}` )
    
* **function** -&gt; ( `@for(todo of todos; track myTrackByFunction) {}` )
    

Hope, I could help you a little bit.
