mining-utils
Version:
[](https://github.com/Oracy/mining-utils/blob/master/LICENSE) [](https://badge.fury.io/js/mining-utils) [;const removeLinks=(e,r)=>{try{const s=r?new RegExp(`${r}://*.[^\\s]+`,"g"):new RegExp("https?://*.[^\\s]+","g");return e.replace(s,"")}catch(e){console.log('This function can handle just strings.\nExample: removeLinks("All your string here")',e)}};exports.removeLinks=removeLinks;const removeLinksArray=(e,r)=>{try{const s=r?new RegExp(`${r}://*.[^\\s]+`,"g"):new RegExp("https?://*.[^\\s]+","g"),n=[];for(const r in e)n.push(e[r].replace(s,""));return n}catch(e){console.log('This function can handle just string arrays.\nExample: removeAcentsArray(["First", "Second", "Third"])',e)}};exports.removeLinksArray=removeLinksArray;