@ts-common/source-map
Advanced tools
Comparing version 0.0.8 to 0.0.9
@@ -31,2 +31,6 @@ import { StringMap } from "@ts-common/string-map"; | ||
export declare const stringMapMap: <T extends Data, R extends Data>(source: StringMap<T>, f: (s: import("@ts-common/tuple").Tuple2<string, T>) => import("@ts-common/tuple").Tuple2<string, R>) => StringMap<R>; | ||
export declare const propertySetMap: <T extends StringMap<string | number | boolean | object | null | undefined>>(source: T, f: propertySet.PartialFactory<T>) => T; | ||
declare type PartialStringMap<K extends string> = { | ||
readonly [k in K]?: Data; | ||
}; | ||
export declare const propertySetMap: <T extends PartialStringMap<keyof T & string>>(source: T, f: propertySet.PartialFactory<T>) => T; | ||
export {}; |
@@ -57,5 +57,6 @@ "use strict"; | ||
}; | ||
const toStringMap = (v) => v; | ||
exports.propertySetMap = (source, f) => { | ||
const result = propertySet.copyCreate(source, f); | ||
if (sm.isEqual(source, result)) { | ||
if (sm.isEqual(toStringMap(source), toStringMap(result))) { | ||
return source; | ||
@@ -65,4 +66,5 @@ } | ||
const sourceValue = source[k]; | ||
if (sourceValue !== undefined) { | ||
exports.copyDataInfo(sourceValue, v); | ||
const vv = v; | ||
if (sourceValue !== undefined && vv !== undefined) { | ||
exports.copyDataInfo(sourceValue, vv); | ||
} | ||
@@ -69,0 +71,0 @@ }); |
{ | ||
"name": "@ts-common/source-map", | ||
"version": "0.0.8", | ||
"version": "0.0.9", | ||
"description": "Source Map", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
17589
107