I have a component in angular with this 3 signal input:
initialPrice = input<number | undefined>();
maxValue = input<number>(999999999);
minValue = input<number>(0);
I want to trigger in effects whenerver an input changes and trigger a functions:
effect(() => {
this.handleNormalizeChange();
this.updateFormattedCurrentPrice();
this.updateValidators(this.minValue(), this.maxValue());
});
Question: how can i trigeer just 1 function if the releted input changes and not all the functions every time effect is executed?
I want basically the functionality of ngOnChanges with previousValue and currentValue.
thanks
New contributor
Lorenzo Del Gaudio is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.