@ts-common/string-map
Advanced tools
Comparing version 0.0.12 to 0.0.13
@@ -11,3 +11,3 @@ import { Tuple2 } from "@ts-common/tuple"; | ||
export interface StringMap<T> { | ||
readonly [key: string]: T; | ||
readonly [key: string]: T | undefined; | ||
} | ||
@@ -18,9 +18,9 @@ export declare type PartialStringMap<K extends string, V> = { | ||
export interface MutableStringMap<T> { | ||
[key: string]: T; | ||
[key: string]: T | undefined; | ||
} | ||
export declare type StringMapItem<T> = T extends StringMap<infer I> ? I : never; | ||
export declare const allKeys: <T>(input: StringMap<T | undefined>) => Iterable<string>; | ||
export declare const entries: <T>(input: StringMap<T | undefined>) => Iterable<Tuple2<string, T>>; | ||
export declare const allKeys: <T>(input: StringMap<T>) => Iterable<string>; | ||
export declare const entries: <T>(input: StringMap<T>) => Iterable<Tuple2<string, T>>; | ||
export declare const keys: <T>(input: StringMap<T>) => Iterable<string>; | ||
export declare const values: <T>(input: StringMap<T | undefined>) => Iterable<T>; | ||
export declare const values: <T>(input: StringMap<T>) => Iterable<T>; | ||
export declare const groupBy: <T>(input: Iterable<Tuple2<string, T>>, reduceFunc: (a: T, b: T) => T) => StringMap<T>; | ||
@@ -27,0 +27,0 @@ export declare const stringMap: <T>(input: Iterable<Tuple2<string, T>>) => StringMap<T>; |
{ | ||
"name": "@ts-common/string-map", | ||
"version": "0.0.12", | ||
"version": "0.0.13", | ||
"description": "String Map", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
16021