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

copy-anything

Package Overview
Dependencies
Maintainers
1
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

copy-anything - npm Package Compare versions

Comparing version 3.0.2 to 3.0.3

9

dist/index.es.js

@@ -21,8 +21,5 @@ import { isArray, isPlainObject } from 'is-what';

*
* @export
* @template T
* @param {T} target Target can be anything
* @param {Options} [options = {}] Options can be `props` or `nonenumerable`
* @returns {T} the target with replaced values
* @export
* @param target Target can be anything
* @param [options = {}] Options can be `props` or `nonenumerable`
* @returns the target with replaced values
*/

@@ -29,0 +26,0 @@ function copy(target, options = {}) {

@@ -1,2 +0,2 @@

export declare type Options = {
export type Options = {
props?: (string | symbol)[];

@@ -8,9 +8,6 @@ nonenumerable?: boolean;

*
* @export
* @template T
* @param {T} target Target can be anything
* @param {Options} [options = {}] Options can be `props` or `nonenumerable`
* @returns {T} the target with replaced values
* @export
* @param target Target can be anything
* @param [options = {}] Options can be `props` or `nonenumerable`
* @returns the target with replaced values
*/
export declare function copy<T>(target: T, options?: Options): T;

@@ -5,3 +5,3 @@ {

"type": "module",
"version": "3.0.2",
"version": "3.0.3",
"description": "An optimised way to copy'ing an object. A small and simple integration",

@@ -27,21 +27,21 @@ "module": "./dist/index.es.js",

"lint": "tsc --noEmit && eslint ./src --ext .ts",
"build": "rollup -c ./scripts/build.js",
"build": "rollup --bundleConfigAsCjs -c ./scripts/build.js",
"release": "npm run lint && del dist && npm run build && np"
},
"dependencies": {
"is-what": "^4.1.6"
"is-what": "^4.1.8"
},
"devDependencies": {
"@typescript-eslint/eslint-plugin": "^5.10.1",
"@typescript-eslint/parser": "^5.10.1",
"del-cli": "^4.0.1",
"eslint": "^8.7.0",
"eslint-config-prettier": "^8.3.0",
"@typescript-eslint/eslint-plugin": "^5.45.0",
"@typescript-eslint/parser": "^5.45.0",
"del-cli": "^5.0.0",
"eslint": "^8.28.0",
"eslint-config-prettier": "^8.5.0",
"eslint-plugin-tree-shaking": "^1.10.0",
"np": "^7.6.0",
"prettier": "^2.5.1",
"rollup": "^2.66.1",
"rollup-plugin-typescript2": "^0.31.1",
"typescript": "^4.5.5",
"vitest": "^0.2.3"
"np": "^7.6.2",
"prettier": "^2.8.0",
"rollup": "^3.5.0",
"rollup-plugin-typescript2": "^0.34.1",
"typescript": "^4.9.3",
"vitest": "^0.25.3"
},

@@ -48,0 +48,0 @@ "keywords": [

@@ -29,12 +29,16 @@ # Copy anything 🎭

copy-anything will copy objects and nested properties, but only as long as they're "plain objects". As soon as a sub-prop is not a "plain object" and has a special prototype, it will copy that instance over "as is". ♻️
## Meet the family (more tiny utils with TS support)
## Meet the family
- [copy-anything 🎭](https://github.com/mesqueeb/copy-anything)
- [is-what 🙉](https://github.com/mesqueeb/is-what)
- [is-where 🙈](https://github.com/mesqueeb/is-where)
- [merge-anything 🥡](https://github.com/mesqueeb/merge-anything)
- [check-anything 👁](https://github.com/mesqueeb/check-anything)
- [remove-anything ✂️](https://github.com/mesqueeb/remove-anything)
- [getorset-anything 🐊](https://github.com/mesqueeb/getorset-anything)
- [map-anything 🗺](https://github.com/mesqueeb/map-anything)
- [filter-anything ⚔️](https://github.com/mesqueeb/filter-anything)
- [find-and-replace-anything 🎣](https://github.com/mesqueeb/find-and-replace-anything)
- [compare-anything 🛰](https://github.com/mesqueeb/compare-anything)
- [copy-anything 🎭](https://github.com/mesqueeb/copy-anything)
- [case-anything 🐫](https://github.com/mesqueeb/case-anything)
- [flatten-anything 🏏](https://github.com/mesqueeb/flatten-anything)
- [is-what 🙉](https://github.com/mesqueeb/is-what)
- [nestify-anything 🧅](https://github.com/mesqueeb/nestify-anything)

@@ -41,0 +45,0 @@ ## Usage

Sorry, the diff of this file is not supported yet

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