Skip to main content

currencyFinder

deno doc

nest badge

find currency information in deno

// pick 1 to import
import * as currencyFinder from "https://deno.land/x/currency_finder/mod.ts";
import * as currencyFinder from "https://x.nest.land/currencyFinder/mod.ts";
import * as currencyFinder from "https://denopkg.com/yeukfei02/currencyFinder/mod.ts";

findCurrencyByCode

const currency = await currencyFinder.findCurrencyByCode("HKD");

findCurrencyByName

const currency = await currencyFinder.findCurrencyByName("hong kong");

findCurrencyBySymbolNative

const currency = await currencyFinder.findCurrencyBySymbolNative("$");

findAll

const currencyList = await currencyFinder.findAll();

// currencyList
[
  {
      symbol: "$",
      name: "US Dollar",
      symbol_native: "$",
      decimal_digits: 2,
      rounding: 0,
      code: "USD",
      name_plural: "US dollars"
    },
    {
      symbol: "CA$",
      name: "Canadian Dollar",
      symbol_native: "$",
      decimal_digits: 2,
      rounding: 0,
      code: "CAD",
      name_plural: "Canadian dollars"
    },
    ...
]