I'm building a react
application and I use Node
(with Express) as a proxy-server. I send data from react app to node-express, then in Node I use that data to form URI and to make requests to another server.
My question is this: Shouldn't 'content-type': 'charset: utf-8'
be enough when I send data including greek characters to Node? For example, I make a post request (using Fetch) to Node and I send code 'ΠΕ0001' using the header I already mentioned. Why do I get the error 'Path contains unescaped characters'? When I use encodeURIComponent
it does work, but why 'charset: utf-8' is not enough?