Gathering detailed insights and metrics for deap
Gathering detailed insights and metrics for deap
Gathering detailed insights and metrics for deap
Gathering detailed insights and metrics for deap
extend and merge objects, deep or shallow, in javascript
npm install deap
Typescript
Module System
Node Version
NPM Version
99
Supply Chain
97
Quality
77.7
Maintenance
100
Vulnerability
100
License
JavaScript (100%)
Total Downloads
53,823,949
Last Day
4,940
Last Week
50,417
Last Month
159,828
Last Year
2,131,985
MIT License
13 Stars
47 Commits
1 Watchers
2 Branches
2 Contributors
Updated on Dec 20, 2022
Minified
Minified + Gzipped
Latest Version
1.0.1
Package Id
deap@1.0.1
Size
6.05 kB
NPM Version
5.5.1
Node Version
8.9.1
Published on
Mar 05, 2018
Cumulative downloads
Total Downloads
===
extend and merge objects, deep or shallow, in javascript
1npm install deap
1var deap = require('deap');
deap assumes es5, so we recommend using an es5 shim for older browsers. Browserify is also recommended as a means to use this module client-side, but other module loaders for browsers will work with deap as well if you shim it.
Deep extend. Copy all the properties from one object onto another, cloning objects deeply.
Takes n number of arguments, modifies the first argument and returns it.
1var a = { name: 'Joe' }; 2 3deap.extend(a, { age: 26 }); // returns: a => { name: 'Joe', age: 26 } 4deap.extend({}, someObj); // clone someObj
Deep merge. Copy properties from one object to another, not replacing existing properties.
Takes n number of arguments, modifies the first argument and returns it.
1var a = { name: 'Joe', address: { number: 1234 }; 2deap.merge(a, { name: 'Jack', age: 26, phone: '555-555-5555', address: { number: 4321, street: 'University Blvd' }); 3// returns: a => { name: 'Joe', age: 26, phone: '555-555-5555', address: { number: 1234, street: 'University Blvd' }}
Deep update. Fill an object's existing properties from another object. For nested objects, a deep update will only update existing properties. Shallow updates will replace nested objects entirely.
Takes n number of arguments, modifies the first argument and returns it.
1var a = { name: 'Joe', phone: '' }; 2deap.update(a, { age: 26, phone: '555-555-5555' }); // returns: a => { name: 'Joe', phone: '555-555-5555' }
If you prefer a shallow-only instance of deap you can require it specifically
1var deap = require('deap/shallow'); 2 3deap() && deap.extend(); // shallow extend 4deap.merge(); //shallow merge 5deap.update(); //shallow update 6deap.clone(); // deep clone
... the end
9.8/10
Summary
Improper Input Validation in Deap
Affected Versions
< 1.0.1
Patched Versions
1.0.1
7.3/10
Summary
Prototype Pollution in deap
Affected Versions
< 1.0.1
Patched Versions
1.0.1
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 3/29 approved changesets -- score normalized to 1
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
35 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-06-23
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn MoreLast Day
264.6%
4,940
Compared to previous day
Last Week
44.3%
50,417
Compared to previous week
Last Month
0.6%
159,828
Compared to previous month
Last Year
-19.1%
2,131,985
Compared to previous year