Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/netzo/core/plugins/auth/utils/display.ts>formatCurrency

Deno-powered framework for building business web apps
Go to Latest
function formatCurrency
import { formatCurrency } from "https://deno.land/x/netzo@0.3.91/core/plugins/auth/utils/display.ts";

Returns a formatted string based on the given amount of currency and the en-US locale. Change the locale for your use case as required.

Examples

Example 1

import { formatCurrency } from "../../../../core/plugins/auth/utils/display.ts";

formatCurrency(5, "USD"); // Returns "$5"

Parameters

amount: number
currency: string

Returns

string