object-set-all-values-to 6.0.16 → 6.0.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
MIT License
|
|
2
2
|
|
|
3
|
-
Copyright (c) 2010-
|
|
3
|
+
Copyright (c) 2010-2025 Roy Revelt and other contributors
|
|
4
4
|
|
|
5
5
|
Permission is hereby granted, free of charge, to any person obtaining
|
|
6
6
|
a copy of this software and associated documentation files (the
|
package/README.md
CHANGED
|
@@ -83,6 +83,6 @@ To report bugs or request features or assistance, [raise an issue](https://githu
|
|
|
83
83
|
|
|
84
84
|
MIT License.
|
|
85
85
|
|
|
86
|
-
Copyright © 2010-
|
|
86
|
+
Copyright © 2010-2025 Roy Revelt and other contributors.
|
|
87
87
|
|
|
88
88
|
<p align="center"><img src="https://codsen.com/images/png-codsen-ok.png" width="98" alt="ok" align="center"> <img src="https://codsen.com/images/png-codsen-1.png" width="148" alt="codsen" align="center"> <img src="https://codsen.com/images/png-codsen-star-small.png" width="32" alt="star" align="center"></p>
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @name object-set-all-values-to
|
|
3
3
|
* @fileoverview Recursively walk the input and set all found values in plain objects to something
|
|
4
|
-
* @version 6.0.
|
|
4
|
+
* @version 6.0.19
|
|
5
5
|
* @author Roy Revelt, Codsen Ltd
|
|
6
6
|
* @license MIT
|
|
7
7
|
* {@link https://codsen.com/os/object-set-all-values-to/}
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
|
-
import d from"rfdc";import{isPlainObject as o}from"codsen-utils";var l="6.0.
|
|
10
|
+
import d from"rfdc";import{isPlainObject as o}from"codsen-utils";var l="6.0.19";var i=d(),y=l;function p(c,r){let t,e=i(c);return arguments.length<2?t=!1:o(r)||Array.isArray(r)?t=i(r):t=r,Array.isArray(e)?e.forEach((s,n)=>{(o(e[n])||Array.isArray(e[n]))&&(e[n]=p(e[n],t))}):o(e)&&Object.keys(e).forEach(s=>{Array.isArray(e[s])||o(e[s])?e[s]=p(e[s],t):e[s]=t}),e}export{p as setAllValuesTo,y as version};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @name object-set-all-values-to
|
|
3
3
|
* @fileoverview Recursively walk the input and set all found values in plain objects to something
|
|
4
|
-
* @version 6.0.
|
|
4
|
+
* @version 6.0.19
|
|
5
5
|
* @author Roy Revelt, Codsen Ltd
|
|
6
6
|
* @license MIT
|
|
7
7
|
* {@link https://codsen.com/os/object-set-all-values-to/}
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
|
-
"use strict";var objectSetAllValuesTo=(()=>{var
|
|
10
|
+
"use strict";var objectSetAllValuesTo=(()=>{var B=Object.create;var h=Object.defineProperty;var D=Object.getOwnPropertyDescriptor;var E=Object.getOwnPropertyNames;var $=Object.getPrototypeOf,M=Object.prototype.hasOwnProperty;var R=(t,n)=>()=>(n||t((n={exports:{}}).exports,n),n.exports),L=(t,n)=>{for(var i in n)h(t,i,{get:n[i],enumerable:!0})},w=(t,n,i,u)=>{if(n&&typeof n=="object"||typeof n=="function")for(let c of E(n))!M.call(t,c)&&c!==i&&h(t,c,{get:()=>n[c],enumerable:!(u=D(n,c))||u.enumerable});return t};var O=(t,n,i)=>(i=t!=null?B($(t)):{},w(n||!t||!t.__esModule?h(i,"default",{value:t,enumerable:!0}):i,t)),P=t=>w(h({},"__esModule",{value:!0}),t);var g=R((Q,v)=>{"use strict";v.exports=F;function y(t){return t instanceof Buffer?Buffer.from(t):new t.constructor(t.buffer.slice(),t.byteOffset,t.length)}function F(t){if(t=t||{},t.circles)return N(t);let n=new Map;if(n.set(Date,s=>new Date(s)),n.set(Map,(s,a)=>new Map(u(Array.from(s),a))),n.set(Set,(s,a)=>new Set(u(Array.from(s),a))),t.constructorHandlers)for(let s of t.constructorHandlers)n.set(s[0],s[1]);let i=null;return t.proto?p:c;function u(s,a){let e=Object.keys(s),r=new Array(e.length);for(let l=0;l<e.length;l++){let o=e[l],f=s[o];typeof f!="object"||f===null?r[o]=f:f.constructor!==Object&&(i=n.get(f.constructor))?r[o]=i(f,a):ArrayBuffer.isView(f)?r[o]=y(f):r[o]=a(f)}return r}function c(s){if(typeof s!="object"||s===null)return s;if(Array.isArray(s))return u(s,c);if(s.constructor!==Object&&(i=n.get(s.constructor)))return i(s,c);let a={};for(let e in s){if(Object.hasOwnProperty.call(s,e)===!1)continue;let r=s[e];typeof r!="object"||r===null?a[e]=r:r.constructor!==Object&&(i=n.get(r.constructor))?a[e]=i(r,c):ArrayBuffer.isView(r)?a[e]=y(r):a[e]=c(r)}return a}function p(s){if(typeof s!="object"||s===null)return s;if(Array.isArray(s))return u(s,p);if(s.constructor!==Object&&(i=n.get(s.constructor)))return i(s,p);let a={};for(let e in s){let r=s[e];typeof r!="object"||r===null?a[e]=r:r.constructor!==Object&&(i=n.get(r.constructor))?a[e]=i(r,p):ArrayBuffer.isView(r)?a[e]=y(r):a[e]=p(r)}return a}}function N(t){let n=[],i=[],u=new Map;if(u.set(Date,e=>new Date(e)),u.set(Map,(e,r)=>new Map(p(Array.from(e),r))),u.set(Set,(e,r)=>new Set(p(Array.from(e),r))),t.constructorHandlers)for(let e of t.constructorHandlers)u.set(e[0],e[1]);let c=null;return t.proto?a:s;function p(e,r){let l=Object.keys(e),o=new Array(l.length);for(let f=0;f<l.length;f++){let b=l[f],d=e[b];if(typeof d!="object"||d===null)o[b]=d;else if(d.constructor!==Object&&(c=u.get(d.constructor)))o[b]=c(d,r);else if(ArrayBuffer.isView(d))o[b]=y(d);else{let j=n.indexOf(d);j!==-1?o[b]=i[j]:o[b]=r(d)}}return o}function s(e){if(typeof e!="object"||e===null)return e;if(Array.isArray(e))return p(e,s);if(e.constructor!==Object&&(c=u.get(e.constructor)))return c(e,s);let r={};n.push(e),i.push(r);for(let l in e){if(Object.hasOwnProperty.call(e,l)===!1)continue;let o=e[l];if(typeof o!="object"||o===null)r[l]=o;else if(o.constructor!==Object&&(c=u.get(o.constructor)))r[l]=c(o,s);else if(ArrayBuffer.isView(o))r[l]=y(o);else{let f=n.indexOf(o);f!==-1?r[l]=i[f]:r[l]=s(o)}}return n.pop(),i.pop(),r}function a(e){if(typeof e!="object"||e===null)return e;if(Array.isArray(e))return p(e,a);if(e.constructor!==Object&&(c=u.get(e.constructor)))return c(e,a);let r={};n.push(e),i.push(r);for(let l in e){let o=e[l];if(typeof o!="object"||o===null)r[l]=o;else if(o.constructor!==Object&&(c=u.get(o.constructor)))r[l]=c(o,a);else if(ArrayBuffer.isView(o))r[l]=y(o);else{let f=n.indexOf(o);f!==-1?r[l]=i[f]:r[l]=a(o)}}return n.pop(),i.pop(),r}}});var V={};L(V,{setAllValuesTo:()=>A,version:()=>H});var k=O(g(),1);var x=O(g(),1);var U=(0,x.default)();function m(t){if(t==null||typeof t!="object")return!1;let n=Object.getPrototypeOf(t);return n!==null&&n!==Object.prototype&&Object.getPrototypeOf(n)!==null?!1:!(Symbol.iterator in t)&&!(Symbol.toStringTag in t)}var C="6.0.19";var S=(0,k.default)(),H=C;function A(t,n){let i,u=S(t);return arguments.length<2?i=!1:m(n)||Array.isArray(n)?i=S(n):i=n,Array.isArray(u)?u.forEach((c,p)=>{(m(u[p])||Array.isArray(u[p]))&&(u[p]=A(u[p],i))}):m(u)&&Object.keys(u).forEach(c=>{Array.isArray(u[c])||m(u[c])?u[c]=A(u[c],i):u[c]=i}),u}return P(V);})();
|
|
11
11
|
/**
|
|
12
12
|
* @name codsen-utils
|
|
13
13
|
* @fileoverview Various utility functions
|
|
14
|
-
* @version 1.6.
|
|
14
|
+
* @version 1.6.7
|
|
15
15
|
* @author Roy Revelt, Codsen Ltd
|
|
16
16
|
* @license MIT
|
|
17
17
|
* {@link https://codsen.com/os/codsen-utils/}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "object-set-all-values-to",
|
|
3
|
-
"version": "6.0.
|
|
3
|
+
"version": "6.0.19",
|
|
4
4
|
"description": "Recursively walk the input and set all found values in plain objects to something",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"all",
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"homepage": "https://codsen.com/os/object-set-all-values-to",
|
|
19
19
|
"repository": {
|
|
20
20
|
"type": "git",
|
|
21
|
-
"url": "https://github.com/codsen/codsen.git",
|
|
21
|
+
"url": "git+https://github.com/codsen/codsen.git",
|
|
22
22
|
"directory": "packages/object-set-all-values-to"
|
|
23
23
|
},
|
|
24
24
|
"license": "MIT",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"examples": "node '../../ops/scripts/run-examples.js'",
|
|
45
45
|
"lect": "node '../../ops/lect/lect.js' && npm run prettier -- 'README.md' '.all-contributorsrc' 'rollup.config.js' --write",
|
|
46
46
|
"letspublish": "npm publish || :",
|
|
47
|
-
"lint": "eslint . --
|
|
47
|
+
"lint": "eslint . --fix",
|
|
48
48
|
"perf": "node perf/check.js",
|
|
49
49
|
"prep": "echo 'ready'",
|
|
50
50
|
"prettier": "prettier",
|
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
}
|
|
72
72
|
},
|
|
73
73
|
"dependencies": {
|
|
74
|
-
"codsen-utils": "^1.6.
|
|
75
|
-
"rfdc": "^1.
|
|
74
|
+
"codsen-utils": "^1.6.7",
|
|
75
|
+
"rfdc": "^1.4.1"
|
|
76
76
|
}
|
|
77
77
|
}
|