5 أسطر
171 B
JavaScript
5 أسطر
171 B
JavaScript
module.exports = function removespace(string) {
|
|
if (typeof string !== "string") throw new TypeError("Meh! Enter a string!!");
|
|
return string.replace(/\s/g, "");
|
|
};
|