1.1.4 • Published 6 years ago

@clarketm/deepclone v1.1.4

Weekly downloads
1
License
MIT
Repository
github
Last release
6 years ago

DeepClone

Light-weight deep clone implementation for JavaScript.

NPM release Build Status

ℹ️ For a standalone Object type with this deep clone implementation, check out the super repository: super/object

Installation

$ npm install @clarketm/deepclone

Modules

Functions

Typedefs

DeepClone

DeepClone(obj, config) ⇒ object

Kind: global method of DeepClone
Returns: object - cloned object

ParamTypeDefault
objobject
configConfig{}

Example

const clone = DeepClone({ key1: ["1", 1, true, (a, b) => a+b], [Symbol("key2")]: {s: "s"} });

console.log(clone);
// { key1: ["1", 1, true, (a, b) => a+b], Symbol("key2"): {s: "s"} }

Config : object

Kind: global typedef
Properties

NameTypeDefault
includeNonEnumerablebooleanfalse
1.1.4

6 years ago

1.1.3

6 years ago

1.1.2

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago