model.idAttribute
  • References/JavaScript/Backbone/Model

idAttributemodel.idAttribute A model's unique identifier is stored under the id attribute. If you're directly communicating

2025-01-10 15:47:30
Model.extend
  • References/JavaScript/Backbone/Model

extendBackbone.Model.extend(properties, [classProperties]) To create a Model class of your own, you extend Backbone.Model

2025-01-10 15:47:30
model.omit
  • References/JavaScript/Backbone/Model

omit

2025-01-10 15:47:30
model.cid
  • References/JavaScript/Backbone/Model

cidmodel.cid A special property of models, the cid or client id is a unique identifier automatically assigned to all models

2025-01-10 15:47:30
model.urlRoot
  • References/JavaScript/Backbone/Model

urlRootmodel.urlRoot or model.urlRoot() Specify a urlRoot if you're using a model outside of a collection, to

2025-01-10 15:47:30
Model
  • References/JavaScript/Backbone/Model

constructor / initializenew Model([attributes], [options]) When creating an instance of a model, you can pass in the initial values

2025-01-10 15:47:30
model.previousAttributes
  • References/JavaScript/Backbone/Model

previousAttributesmodel.previousAttributes() Return a copy of the model's previous attributes. Useful for getting a diff between

2025-01-10 15:47:30
model.previous
  • References/JavaScript/Backbone/Model

previousmodel.previous(attribute) During a "change" event, this method can be used to get the previous value of a changed

2025-01-10 15:47:30
model.isValid
  • References/JavaScript/Backbone/Model

isValidmodel.isValid() Run validate to check the model

2025-01-10 15:47:30
model.isNew
  • References/JavaScript/Backbone/Model

isNewmodel.isNew() Has this model been saved to the server yet? If the model does not yet have an id, it is considered

2025-01-10 15:47:30