Closed
Description
I have a use case where I want to use the json_encode option JSON_UNESCAPED_SLASHES
. I noticed that Symfony\Component\HttpFoundation\JsonResponse doesn’t allow to change the json options.
Would you accept a PR which allows you to change the options?
I was thinking about something like
$response = new JsonResponse();
$response->setOptions(JSON_UNESCAPED_SLASHES);
$response->setData($data);
or
JsonResponse::setOptions(JSON_UNESCAPED_SLASHES);
$response = new JsonResponse($data);
ping @igorw