I have been reading a bit on JSON and rails (I am new to both) and I am trying to understand why JSON is useful and how it is used. I know this is a fairly vague question however I would like to understand it’s principal application and why it is preferred over other methods. I’ve watched and read numeral tutorials on how to use it, but haven’t come across anything that explains the fundamentals as to why it is used. If any of you have specific links on JSON with rails and how the two interact and more importantly why it is used it would be very much appreciated. Cheers.
Share
Why is it used? Because it’s a simple, ubiquitous, trivially-parsed way to exchange data.
There’s no intrinsic relationship between Rails and JSON–it’s one of the normal formats it supports because so many things can consume JSON, like JS libraries (jQuery UI, for example).