This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const YOUR_TEXT = "كتاب العين للخليل بن أحمد الفراهيدي" | |
function arabicToHebrew(str) { | |
const mapping = { | |
"ا": "א", | |
"ب": "ב", | |
"ج": "ג'", | |
"د": "ד", | |
"ذ": "ד'", | |
"ه": "ה", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getIPA(str) { | |
const mapping = { | |
"oi": "ɔɪ", | |
"ou": "aʊ", | |
"ô": "ɔ", | |
"ä": "ɑ", | |
"a": "æ", | |
"æʊ": "aʊ", | |
"i": "ɪ", | |
"ē": "i", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { writeFile, readFile } from 'node:fs'; | |
import fetch from "node-fetch"; | |
async function getCoordinatesByAddress(address) { | |
const api = `https://maps.googleapis.com/maps/api/geocode/json?address=${address}&key=MY_API_KEY`; | |
const response = await fetch(api); | |
const data = await response.json(); | |
return data; | |
} |