Check-AF-A-Javascript-String-IS-A-Url
const isUrl = string => {
try { return Boolean(new URL(string)); }
catch(e){ return false; }
}
Borma
const isUrl = string => {
try { return Boolean(new URL(string)); }
catch(e){ return false; }
}