File

projects/apttus/ecommerce/src/lib/modules/pricing/pipes/price.pipe.ts

Description

Provides pricing for a given product option NOTE: It is recommend you use the PriceComponent component when rendering price as it has been optimized for change detection.

Example:

 <!-- The totalPrice attribute on the returned price instance will be the number value of the price (i.e. 9.99) -->
 <span>{{(productOption | OptionPricePipe:1 | async)?.totalPrice}}<span>

 <!-- To get the formatted price (i.e. $9.99), use netPrice$ instead of totalPrice property and pass it through the async pipe again -->
 <span>{{(productOption | OptionPricePipe:1 | async)?.netPrice$ | async}}<span>

Metadata

Name OptionPricePipe

Methods

transform
transform(option: ProductOptionComponent, quantity: number)
Parameters :
Name Type Optional
option ProductOptionComponent No
quantity number No
Returns : Observable<Price>

result-matching ""

    No results matching ""