Let CDK

Examples Setup

Directive tuiLet allows to reuse computed value in several places in template to avoid recalculations of getters or many async pipes

With Pipe

#

Timer value:

It can be used many times:

It subscribed once and async pipe unsubscribed it after component destroy

With getter

#

Calculated with getter value: 🐳

That can be used many times: 🐳

And getter is called only once.