New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

cosmokit

Package Overview
Dependencies
Maintainers
0
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cosmokit - npm Package Compare versions

Comparing version 1.6.3 to 1.7.0

1

lib/index.d.ts

@@ -12,2 +12,3 @@ export type Dict<T = any, K extends string | symbol = string> = {

export function isNullable(value: any): value is null | undefined | void;
export function isNonNullable<T>(value: T): value is NonNullable<T>;
export function isPlainObject(data: any): any;

@@ -14,0 +15,0 @@ export function filterKeys<T, K extends string, U extends K>(object: Dict<T, K>, filter: (key: K, value: T) => key is U): Dict<T, U>;

6

package.json
{
"name": "cosmokit",
"description": "A collection of common utilities",
"version": "1.6.3",
"version": "1.7.0",
"sideEffects": false,

@@ -45,3 +45,3 @@ "type": "module",

"@types/mocha": "^9.1.1",
"@types/node": "^22.1.0",
"@types/node": "^22.7.5",
"@types/sinonjs__fake-timers": "^6.0.4",

@@ -55,4 +55,4 @@ "c8": "^7.14.0",

"shx": "^0.3.4",
"typescript": "^5.5.3"
"typescript": "^5.6.2"
}
}

@@ -15,2 +15,6 @@ export type Dict<T = any, K extends string | symbol = string> = { [key in K]: T }

export function isNonNullable<T>(value: T): value is NonNullable<T> {
return !isNullable(value)
}
export function isPlainObject(data: any) {

@@ -17,0 +21,0 @@ return data && typeof data === 'object' && !Array.isArray(data)

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

import { isNullable, mapValues } from './misc'
import { isNullable } from './misc'

@@ -84,3 +84,7 @@ type GlobalConstructorNames = keyof {

if (ArrayBuffer.isView(source)) return source.buffer.slice(source.byteOffset, source.byteOffset + source.byteLength)
return mapValues(source, clone)
const result = Object.create(Object.getPrototypeOf(source))
for (const key of Reflect.ownKeys(source)) {
Reflect.defineProperty(result, key, Reflect.getOwnPropertyDescriptor(source, key)!)
}
return result
}

@@ -87,0 +91,0 @@

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

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