Hi folks,
in Rails 2.3 I always used
render :json => { :success => true, :data => @foobar}
to send JSON data to my frontend. In Rails 3 I'm using
respond_to :json
...
respond_with @foobar
But what I'm missing: I need the 'success' value within the JSON structure. What's the right way to inject such data into JSON response in Rails 3?
Cheerio, Chris