URL Slugs not working

URL Slugs not working



let slug = globalTitle.toLowerCase().split(" ").join("-");
return slug;

Why wouldn’t this code pass the test? is not as valid as using regex and filter?
Besides, the request is not to use replace.


Use the title parameter instead of the globalTitle variable. It still won’t solve everything though


Good spot. Thank you.
Still. It´s working on codepen, not in FCC.
EDIT: Aaaah… hold on. Found out why.