I have a dropdown with various currency types. I want to display all the currencies rates into selected currency type rates all over the page. After a research, I found this can be solved by creating custom pipe in angular. How this can be done?
I already created custom pipe but under transform function how I can into covert the selected currency type.
<form>
<div class="form-group pt-2 display-inline">
<select class="form-control w-200 display-inline" [(ngModel)]="dataService.selectedCurrency" (change)="currencySelected($event)">
<option disabled>Select Currency</option>
<option *ngFor="let item of _dataList.Currency" value="{{item.key}}">
{{item.value}}
</option>
</select>
</div>
</form>
The currency should be converted into the selected currency type and respective rate should be changed to all over page.