Backbone.JS emulateJSON()

The Backbone.JS emulateJSON() method is used to handle the requests encoded with application/JSON.

Syntax:

Backbone.emulateJSON = true  

Example:

  

  
Example  
  
  
  
  
  
  
  
  

Output:

create:{"name":"Tom","city":"London"}update: {"name":"Tom","city":"London","id":100,"age":10}
Please follow and like us:
Content Protection by DMCA.com