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

extra-utils

Package Overview
Dependencies
Maintainers
1
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

extra-utils - npm Package Compare versions

Comparing version 5.5.0 to 5.5.1

2

lib/enum/enum-entries.d.ts

@@ -1,3 +0,3 @@

export declare function enumEntries<T extends Record<string | number, string | number>>(_enum: T): Array<{
export declare function enumEntries<T extends Record<string, string | number>>(_enum: T): Array<{
[Key in keyof T]: [Key, T[Key]];
}[keyof T]>;

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

export declare function enumKeys<T extends Record<string | number, string | number>>(_enum: T): Array<keyof T>;
export declare function enumKeys<T extends Record<string, string | number>>(_enum: T): Array<keyof T>;

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

export declare function enumValues<T extends Record<string | number, string | number>>(_enum: T): Array<T[keyof T]>;
export declare function enumValues<T extends Record<string, string | number>>(_enum: T): Array<T[keyof T]>;

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

export declare function inEnum<T extends Record<string | number, string | number>>(val: string | number, _enum: T): val is T[keyof T];
export declare function notInEnum(val: string | number, _enum: Record<string | number, string | number>): boolean;
export declare function inEnum<T extends Record<string, string | number>>(val: string | number, _enum: T): val is T[keyof T];
export declare function notInEnum(val: string | number, _enum: Record<string, string | number>): boolean;
{
"name": "extra-utils",
"version": "5.5.0",
"version": "5.5.1",
"description": "Utilities for JavaScript and Typescript",

@@ -5,0 +5,0 @@ "files": [

@@ -194,3 +194,3 @@ # extra-utils

```ts
function inEnum<T extends Record<string | number, string | number>>(
function inEnum<T extends Record<string, string | number>>(
val: string | number

@@ -201,12 +201,12 @@ , _enum: T

val: string | number
, _enum: Record<string | number, string | number>
, _enum: Record<string, string | number>
): boolean
function enumKeys<T extends Record<string | number, string | number>>(
function enumKeys<T extends Record<string, string | number>>(
_enum: T
): Array<keyof T>
function enumValues<T extends Record<string | number, string | number>>(
function enumValues<T extends Record<string, string | number>>(
_enum: T
): Array<T[keyof T]>
function enumEntries<T extends Record<string | number, string | number>>(
function enumEntries<T extends Record<string, string | number>>(
_enum: T

@@ -213,0 +213,0 @@ ): Array<{ [Key in keyof T]: [Key, T[Key]] }[keyof T]>

import { enumKeys } from './enum-keys.js'
export function enumEntries<T extends Record<string | number, string | number>>(
export function enumEntries<T extends Record<string, string | number>>(
_enum: T

@@ -5,0 +5,0 @@ ): Array<{ [Key in keyof T]: [Key, T[Key]] }[keyof T]> {

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

export function enumKeys<T extends Record<string | number, string | number>>(
export function enumKeys<T extends Record<string, string | number>>(
_enum: T

@@ -3,0 +3,0 @@ ): Array<keyof T> {

import { enumKeys } from './enum-keys.js'
export function enumValues<T extends Record<string | number, string | number>>(
export function enumValues<T extends Record<string, string | number>>(
_enum: T

@@ -5,0 +5,0 @@ ): Array<T[keyof T]> {

import { enumValues } from './enum-values.js'
export function inEnum<T extends Record<string | number, string | number>>(
export function inEnum<T extends Record<string, string | number>>(
val: string | number

@@ -13,5 +13,5 @@ , _enum: T

val: string | number
, _enum: Record<string | number, string | number>
, _enum: Record<string, string | number>
): boolean {
return !inEnum(val, _enum)
}

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