UNPKG

num-to-arabic

Version:
10 lines (9 loc) 302 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); //Convert numbers function convertToArabic(number) { return number .toString() .replace(/\d/g, (x) => ["٠", "١", "٢", "٣", "٤", "٥", "٦", "٧", "٨", "٩"][x]); } exports.default = convertToArabic;