Socket
Socket
Sign inDemoInstall

backbone-deepextend

Package Overview
Dependencies
4
Maintainers
2
Versions
5
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    backbone-deepextend

A Backbone extend implementation that merges properties rather than overrides"


Version published
Weekly downloads
8
increased by700%
Maintainers
2
Install size
1.12 MB
Created
Weekly downloads
 

Readme

Source

backbone-deepextend

A Backbone extend implementation that merges properties rather than overrides". Useful for inheritting defaults and other attributes which are objects on a model.

Travis build status Code Climate Test Coverage Dependency Status devDependency Status

This module should be imported before any models that need this functionality are derived as <Class>.extend is written on all objects on creation time.

require('backbone-deepextend');

var Model = Backbone.Model.extend({
    defaults: {
        a: 1
    }
}).extend({
    defaults: {
        b: 2
    }
})

var model = new Model;
model.get('a') // => 1
model.get('b') // => 2

FAQs

Last updated on 06 May 2016

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc