import type { DeepPath, Maybe, OptPathVal, Path, Path0, Path1, Path2, Path3, Path4, Path5, Path6, Path7, Path8 } from "@thi.ng/api"; /** * Non-typechecked version of {@link getIn}. Returns `undefined` if path is * invalid. * * @remarks * The type parameter `T` can be used to indicate the type of the nested value * to be retrieved (default: `any`). * * @example * ```ts tangle:../export/get-in-unsafe.ts * import { getInUnsafe } from "@thi.ng/paths"; * * console.log( * getInUnsafe({ a: { b: { c: 23 } } }, "a.b.c") * ); * // 23 * ``` * * @param state - * @param path - */ export declare const getInUnsafe: (state: any, path: Path) => Maybe; /** * Type checked, immediate use getter, i.e. same as: * `defGetter(path)(state)`. * * @remarks * Only the first 8 path levels are type checked. * * @example * ```ts tangle:../export/get-in.ts * import { getIn } from "@thi.ng/paths"; * * // type checked path and inferred return type * console.log( * getIn({ a: { b: { c: 23 } } }, ["a","b","c"]) * ); * // 23 * ``` * * @param state - * @param path - */ export declare function getIn(state: T, path: Path0): T; export declare function getIn(state: T, path: Path1): OptPathVal; export declare function getIn(state: T, path: Path2): OptPathVal; export declare function getIn(state: T, path: Path3): OptPathVal; export declare function getIn(state: T, path: Path4): OptPathVal; export declare function getIn(state: T, path: Path5): OptPathVal; export declare function getIn(state: T, path: Path6): OptPathVal; export declare function getIn(state: T, path: Path7): OptPathVal; export declare function getIn(state: T, path: Path8): OptPathVal; export declare function getIn(state: T, path: DeepPath): any; //# sourceMappingURL=get-in.d.ts.map