only update certain model attributes using Backbone.js
- by Drew Dara-Abrams
With Backbone, I'm trying to update and save to the server just one attribute:
currentUser.save({hide_explorer_tutorial: 'true'});
but I don't want to send all the other attributes. Some of them are actually the output of methods on the server-side and so they are not actually true attributes with setter functions.
Currently I'm using unset(attribute_name) to remove all the attributes that I don't want to update on the server. Problem is those attributes are then no longer available for local use.
Suggestions on how to only save certain attributes to the server?