I am using Axios to get some data from the server based on the date range.
this is my sample Axios request
const params = {
fromdate: encodeURIComponent(datefrom),
};
axios
.get(url, {params})
I am using the following method to encode the data
encodeURIComponent(_.toString(datefrom))
The server accepting the following patterns
**Encoded Type:** fromdate: 2020-11-01%200%3A0%3A00
**Decoded Type:** fromdate: 2020-11-01 0:0:00
But while I am passing to the server I am getting like that
**Encoded Type:** fromdate: 2020-11-01%200%3A0%3A00
**Decoded Type:** 2020-11-01%25200%253A0%253A00
How can I get the Decoded type like
Decoded Type: fromdate: 2020-11-01 0:0:00
instead of
Decoded Type: 2020-11-01%25200%253A0%253A00