3 ms·
I am very curious about this: "To implement the remaining presentation logic, we used the route suggested by Backbone.js, preparing the data for output in the M
by meta 15y ago
I am very curious about this:
"To implement the remaining presentation logic, we used the route suggested by Backbone.js, preparing the data for output in the Model’s toJSON method."
I don't quite know why you would toJSON the model for the view vs. just accessing the models members via .escape() when you need them. Has anyone else used the toJSON function to format models for output to a view?
- jzaefferer 15y agoWe use that for example for formatting a timestamp into an "5 hours ago" format.