export function getObjectEntryByKey(key: string, data: { [key: string]: any }): any | undefined {
  let entry = data;
  for (const part of key.split('.')) {
    entry = entry[part];
    if (entry === null || typeof entry !== 'object') return entry;
  }
  return entry;
}
