I am using CurrencyPipe with my application,
The following works,
<div class="price">{{123 | currConvert | currency:'USD':true:'3.2-2'}}</div>
Now I need to transfer the currency from the model variable, this is what I do,
ngOnInit() {
this.selectedCurrency = 'USD';
}
and in the template
<div class="price">{{123 | currConvert | currency:{{selectedCurrency}}:true:'3.2-2'}}</div>
it gives me the parsing error of the template. what is the problem.
source
share