/** * Removes the vowels from a name. * * @param {string} name The name of the domain. * @return The name with the vowels removed. * @customfunction */ function REMOVE_VOWELS(name) { const vowels = ["a", "e", "i", "o", "u"]; const letters = name.toLowerCase().split(""); let newName = []; letters.map(letter => vowels.includes(letter) ? null : newName.push(letter)); return newName.join(""); }
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter