Javatpoint Logo
Javatpoint Logo

Backbone.js model.previousAttributes()

The Backbone.js PreviousAttributes model returns the model's previous attributes before the last change event. It is used to get the difference between the versions of a model, or restore the previous attributes after an error occurs.

Syntax:

Let's take an example.

See this example:

Test it Now

Output:

Save the above code in previousattributes.html file and open this file in a new browser.

BackboneJS previousattributes Model




Youtube For Videos Join Our Youtube Channel: Join Now

Feedback


Help Others, Please Share

facebook twitter pinterest

Learn Latest Tutorials


Preparation


Trending Technologies


B.Tech / MCA