I'm working on a project which deals with strings a lot. I need to show what kind of delimiter is used in strings. I get that value from an API call. How do I print the delimiter to the console?
delimiter = '\n';
I want to print this on screen.
console.log(delimiter);
// prints "
"
I need it to print \n instead of literally printing newline.
delimiter = '\\n';, perhaps?