@iamjr15/react-currency-localizer
Version:
A React hook to display prices in a user's local currency using HTTPS-compatible IP geolocation with robust validation and error handling
14 lines • 686 B
TypeScript
import { default as React } from 'react';
import { LocalizedPriceProps } from '../types';
/**
* A React component that automatically displays a price in the user's local currency.
*
* This component wraps the useCurrencyConverter hook and provides a simple,
* declarative API for displaying localized prices. It handles loading states,
* error states, and automatic formatting using the Intl.NumberFormat API.
*
* @param props Configuration props for the localized price display
* @returns JSX element with the formatted price or appropriate loading/error state
*/
export declare const LocalizedPrice: React.FC<LocalizedPriceProps>;
//# sourceMappingURL=LocalizedPrice.d.ts.map