Add JSONP support to MappingJackson2MessageConverter [SPR-9899] #14532
Labels
in: web
Issues in web modules (web, webmvc, webflux, websocket)
type: enhancement
A general enhancement
Milestone
Uh oh!
There was an error while loading. Please reload this page.
Johan Sjöberg opened SPR-9899 and commented
To implement a JSONP (padded json) HttpMessageConverter a parameter from the Servlet request map is necessary (e.g., ?callback=foo) which affects the produced JSON output.
E.g., if a regular JSON response is {json}, then JSONP for value foo is
foo({json});
One option would be the add the HttpServletRequest or similar to:
HttpMesageConverter.write(T t, MediaType contentType, HttpOutputMessage outputMessage)
Affects: 4.0.5
Issue Links:
@ResponseBody
("depends on")The text was updated successfully, but these errors were encountered: