Angular Peformance Guidelines
Runtime strategies
These are the strategies we can use while the application is running in the browser.
Avoid function calls in view templates
Angular's zone can perform change detection every time there is a user interaction on the document, such as during a click, mouse move, timer tick, or http call. Therefore function calls in the template get invoked and recalculated each time this happens. This can add a lot of unnecessary overhead during runtime especially with complex logic or multiple function calls