Skip to content

getNestedPropertyValue

Gets the value of a nested property from an object.

Import:

import { getNestedPropertyValue } from 'obsidian-dev-utils/object-utils';

Signature:

function getNestedPropertyValue(obj: Record<string | symbol, unknown>, path: string): unknown

Parameters:

ParameterTypeDescription
objRecord<string | symbol, unknown>The object to get the nested property value from.
pathstringThe path to the nested property.

Returns: unknown — The value of the nested property.