Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

deep-clone-simple

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

deep-clone-simple

Tiny deep clone utility for simple data structures.

  • 1.1.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
3.8K
increased by1.17%
Maintainers
1
Weekly downloads
 
Created
Source

Deep clone simple

Deep clone utlity function for JavaScript that is limited to basic data types:

  • Objects { hello: 2 }
  • Array [1, 2, 3]
  • Number 5.2
  • Boolean true
  • String "hello"
  • Date new Date()
  • Functions function bla() {}
  • null

Minimizes to 279 bytes.

Only works with modern bundlers that support the module entry point like Rollup, Webpack 2+.

Installation

yarn add deep-clone-simple

Usage

import deepClone from 'deep-clone-simple';

const copy = deepClone(someData);

Run tests

yarn test
yarn test-watch

FAQs

Package last updated on 30 Jun 2017

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc