Rails provides an excellent XML Builder by default to build RSS and ATOM feeds, but nothing to help you build complex and custom JSON data structures. JSON Builder is here to help.
When using keys that match Rails helper method names, like:
dom_id "le-dom-id"
url_for "le-url"
JSONBuilder calls the Rails helper methods instead of generating a key with the corresponding value.
Using key :dom_id, "le-dom-id" does not work either.
When using keys that match Rails helper method names, like:
JSONBuilder calls the Rails helper methods instead of generating a key with the corresponding value. Using
key :dom_id, "le-dom-id"
does not work either.