Socket
Socket
Sign inDemoInstall

@rimbu/common

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rimbu/common - npm Package Compare versions

Comparing version 0.12.0 to 0.12.1

4

dist/types/async-optlazy.d.ts

@@ -6,3 +6,3 @@ import type { OptLazy } from './internal';

*/
export declare type MaybePromise<T> = T | Promise<T>;
export type MaybePromise<T> = T | Promise<T>;
/**

@@ -12,3 +12,3 @@ * A potentially lazy and/or asynchronous value of type T.

*/
export declare type AsyncOptLazy<T> = OptLazy<MaybePromise<T>>;
export type AsyncOptLazy<T> = OptLazy<MaybePromise<T>>;
export declare namespace AsyncOptLazy {

@@ -15,0 +15,0 @@ /**

@@ -8,3 +8,3 @@ import { AsyncCollectFun, AsyncOptLazy, MaybePromise, Reducer, Eq } from './internal';

*/
export declare type AsyncReducer<I, O = I> = AsyncReducer.Impl<I, O, unknown>;
export type AsyncReducer<I, O = I> = AsyncReducer.Impl<I, O, unknown>;
export declare namespace AsyncReducer {

@@ -11,0 +11,0 @@ interface Impl<I, O, S> {

@@ -10,3 +10,3 @@ import type { MaybePromise } from './internal';

*/
export declare type CollectFun<T, R> = (value: T, index: number, skip: CollectFun.Skip, halt: () => void) => R | CollectFun.Skip;
export type CollectFun<T, R> = (value: T, index: number, skip: CollectFun.Skip, halt: () => void) => R | CollectFun.Skip;
export declare namespace CollectFun {

@@ -30,2 +30,2 @@ /**

*/
export declare type AsyncCollectFun<T, R> = (value: T, index: number, skip: CollectFun.Skip, halt: () => void) => MaybePromise<R | CollectFun.Skip>;
export type AsyncCollectFun<T, R> = (value: T, index: number, skip: CollectFun.Skip, halt: () => void) => MaybePromise<R | CollectFun.Skip>;
/**
* A function returning true if given `v1` and `v2` should be considered equal.
*/
export declare type Eq<T> = (v1: T, v2: T) => boolean;
export type Eq<T> = (v1: T, v2: T) => boolean;
export declare namespace Eq {

@@ -6,0 +6,0 @@ function convertAnyToString(value: any): string;

@@ -20,3 +20,3 @@ import type { Range } from './internal';

*/
export declare type IndexRange = {
export type IndexRange = {
amount: number;

@@ -23,0 +23,0 @@ start?: number | [number, boolean];

@@ -5,3 +5,3 @@ /**

*/
export declare type OptLazy<T> = T | (() => T);
export type OptLazy<T> = T | (() => T);
/**

@@ -24,3 +24,3 @@ * Returns the value contained in an `OptLazy` instance of type T.

*/
export declare type OptLazyOr<T, O> = T | ((none: O) => T | O);
export type OptLazyOr<T, O> = T | ((none: O) => T | O);
/**

@@ -27,0 +27,0 @@ * Returns the value contained in an `OptLazyOr` instance of type T, or the given

@@ -16,3 +16,3 @@ /**

*/
export declare type Range<T> = {
export type Range<T> = {
start: T | [T, boolean];

@@ -19,0 +19,0 @@ end?: T | [T, boolean];

@@ -7,3 +7,3 @@ import { CollectFun, Eq, OptLazy } from './internal';

*/
export declare type Reducer<I, O = I> = Reducer.Impl<I, O, unknown>;
export type Reducer<I, O = I> = Reducer.Impl<I, O, unknown>;
export declare namespace Reducer {

@@ -10,0 +10,0 @@ /**

@@ -5,3 +5,3 @@ /**

*/
export declare type SuperOf<U, T> = T extends U ? U : never;
export type SuperOf<U, T> = T extends U ? U : never;
/**

@@ -11,15 +11,15 @@ * Accepts all types of T and S where S extends T,

*/
export declare type SubOf<S, T> = S extends T ? S : never;
export type SubOf<S, T> = S extends T ? S : never;
/**
* Accepts all types of T and U where T extends U or U extends T.
*/
export declare type RelatedTo<T, U> = T | SuperOf<U, T>;
export type RelatedTo<T, U> = T | SuperOf<U, T>;
/**
* Accepts all arrays with at least one element.
*/
export declare type ArrayNonEmpty<T> = [T, ...T[]];
export type ArrayNonEmpty<T> = [T, ...T[]];
/**
* Accepts all strings with at least one character.
*/
export declare type StringNonEmpty<T> = T extends string ? '' extends T ? never : T : never;
export type StringNonEmpty<T> = T extends string ? '' extends T ? never : T : never;
/**

@@ -26,0 +26,0 @@ * Utility type to convert some object to a JSON serializable format.

/**
* A value of type T, or a function taking a value of type T and returning a new value of type T.
*/
export declare type Update<T> = T | ((value: T) => T);
export type Update<T> = T | ((value: T) => T);
/**

@@ -6,0 +6,0 @@ * Returns the result of given `update` parameter, where it can either directly give a new value,

{
"name": "@rimbu/common",
"version": "0.12.0",
"version": "0.12.1",
"description": "Common types and objects used in many other Rimbu packages",

@@ -61,5 +61,5 @@ "keywords": [

"dependencies": {
"tslib": "^2.4.0"
"tslib": "^2.5.0"
},
"gitHead": "442ffd299583458d458e9bbe3dd02c67828707f3"
"gitHead": "f7a7662f81e9246b244cab22c14776617652833f"
}

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