Installation
npm install --save @types/set-value
Summary
This package contains type definitions for set-value (https://github.com/jonschlinkert/set-value).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/set-value.
export = set;
declare function set<T extends object, K extends keyof T>(object: T, path: K, value: T[K], options?: set.Options): void;
declare function set(object: object, path: set.InputType, value: any, options?: set.Options): void;
declare namespace set {
interface Options {
preservePaths?: boolean | undefined;
separator?: string | undefined;
split?: SplitFunc | undefined;
merge?: boolean | MergeFunc | undefined;
}
type InputType = string | symbol | ReadonlyArray<string | symbol>;
type MergeFunc = <TObject, TSource>(object: TObject, source: TSource) => TObject & TSource;
type SplitFunc = (input: string, options?: Options) => string;
}
Additional Details
- Last updated: Tue, 07 Nov 2023 15:11:36 GMT
- Dependencies: none
Credits
These definitions were written by Daniel Rosenwasser, and Piotr Błażejewicz.