Home > widget-integration > FilterController > buildPriceHTML
FilterController.buildPriceHTML() method
Builds formatted price HTML for product items
Signature:
protected buildPriceHTML(priceMin: string, compareAtPriceMin: string, priceMax: string, options: {
showCentAsSuperscript: boolean;
showCurrencyCodes: boolean;
compareAtPricePosition: string;
showSavingDisplay: boolean;
textAlign: string;
productItemSavingAmountTranslation: string;
productItemAmountTranslation: string;
}): Promise<string>;
Parameters
|
Parameter |
Type |
Description |
|---|---|---|
|
priceMin |
string |
Minimum price |
|
compareAtPriceMin |
string |
Compare at price for min |
|
priceMax |
string |
Maximum price (for multi-variant) |
|
options |
{ showCentAsSuperscript: boolean; showCurrencyCodes: boolean; compareAtPricePosition: string; showSavingDisplay: boolean; textAlign: string; productItemSavingAmountTranslation: string; productItemAmountTranslation: string; } |
Formatting options |
Returns:
Promise<string>
HTML string with formatted prices