this is my current problem, so i passed stringified array to client from server and i was trying to get it with following code
const stringifiedArray = "<%= array %>";
and it was returning string but when i was trying to parse it, it was returning JSON error "Unexpected Token in position N" and when i changed double quotes with backquote and equation sign with minus sign: (backquote)<%-array%>
(backquote)
it worked and parsed perfectly, but what is i wanted escaped string to be parsed? how can i do that?