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

lib0

Package Overview
Dependencies
Maintainers
1
Versions
113
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

lib0 - npm Package Compare versions

Comparing version 0.2.97 to 0.2.98

coverage/tmp/coverage-165735-1727438709799-0.json

3

bin/0serve.js

@@ -26,3 +26,4 @@ #!/usr/bin/env node

json: 'application/json',
xml: 'application/xml'
xml: 'application/xml',
wasm: 'application/wasm'
}

@@ -29,0 +30,0 @@

@@ -45,2 +45,14 @@ export function create(): {

}): boolean;
/**
* Make an object immutable. This hurts performance and is usually not needed if you perform good
* coding practices.
*/
export const freeze: {
<T extends Function>(f: T): T;
<T_1 extends {
[idx: string]: object | U | null | undefined;
}, U extends string | number | bigint | boolean | symbol>(o: T_1): Readonly<T_1>;
<T_2>(o: T_2): Readonly<T_2>;
};
export function deepFreeze<T extends unknown>(o: T): Readonly<T>;
//# sourceMappingURL=object.d.ts.map
export function testObject(_tc: t.TestCase): void;
export function testFreeze(_tc: t.TestCase): void;
import * as t from './testing.js';
//# sourceMappingURL=object.test.d.ts.map
/**
* Isomorphic module to work access the environment (query params, env variables).
*
* @module map
* @module environment
*/

@@ -6,0 +6,0 @@

@@ -45,2 +45,14 @@ export function create(): {

}): boolean;
/**
* Make an object immutable. This hurts performance and is usually not needed if you perform good
* coding practices.
*/
export const freeze: {
<T extends Function>(f: T): T;
<T_1 extends {
[idx: string]: object | U | null | undefined;
}, U extends string | number | bigint | boolean | symbol>(o: T_1): Readonly<T_1>;
<T_2>(o: T_2): Readonly<T_2>;
};
export function deepFreeze<T extends unknown>(o: T): Readonly<T>;
//# sourceMappingURL=object.d.ts.map

@@ -116,1 +116,25 @@ /**

export const equalFlat = (a, b) => a === b || (size(a) === size(b) && every(a, (val, key) => (val !== undefined || hasProperty(b, key)) && b[key] === val))
/**
* Make an object immutable. This hurts performance and is usually not needed if you perform good
* coding practices.
*/
export const freeze = Object.freeze
/**
* Make an object and all its children immutable.
* This *really* hurts performance and is usually not needed if you perform good coding practices.
*
* @template {any} T
* @param {T} o
* @return {Readonly<T>}
*/
export const deepFreeze = (o) => {
for (const key in o) {
const c = o[key]
if (typeof c === 'object' || typeof c === 'function') {
deepFreeze(o[key])
}
}
return freeze(o)
}
export function testObject(_tc: t.TestCase): void;
export function testFreeze(_tc: t.TestCase): void;
import * as t from './testing.js';
//# sourceMappingURL=object.test.d.ts.map
{
"name": "lib0",
"version": "0.2.97",
"version": "0.2.98",
"description": "",

@@ -5,0 +5,0 @@ "sideEffects": false,

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

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