I want to return html content via jbuilder:
json.array!(@articles) do |article| json.extract! article, :id, :title, :html_content end
But it returns escaped html:
{ "id": 2, "title": "", "html_content": "\u003cp\u003e\u003cimg alt=\"\" src=\"#\" /\u003e\u003c/p\u003e\r\n" }
How can it return unescaped html?
source share