Answers for "javascript money to arab currency"

0

javascript money to arab currency

function eArabic(x){
  return x.toLocaleString('ar-EG');
}

console.log(eArabic(123456.789));
// expected output: "١٢٣٬٤٥٦٫٧٨٩"

console.log(eArabic('123456.789'));
// expected output: "123456.789"

console.log(eArabic(NaN));
// expected output: "ليس رقم"
Posted by: Guest on July-13-2021

Code answers related to "javascript money to arab currency"

Code answers related to "Javascript"

Browse Popular Code Answers by Language