I have an input JSON like this (which really contains the literal values "\u2013
" (the encoded form of a unicode character)):
{"source":"Subject: NEED: 11/5 BNA-MSL \u2013 1200L Departure - 1 Pax"}
I read it with JSON.parse
and it reads the \u2013
as –
, which is fine for display in my app.
However, I need to export again the same JSON, to send it down to some other app. I want to keep the same format and have back the \u2013
into the JSON. I am doing JSON.stringify
, but it keeps the –
in the output.
Any idea what I could do to keep the \u
syntax?