function resolveFieldValue(dottedFieldPath, nodeOrThunk, resolvedNodeFields) {
  let result;

  if (resolvedNodeFields) {
    result = (0, _getValueAt.getValueAt)(resolvedNodeFields, dottedFieldPath);
  }

  if (typeof result !== `undefined`) {
    return result;
  }

  const node = typeof nodeOrThunk === `function` ? nodeOrThunk() : nodeOrThunk;
  return (0, _getValueAt.getValueAt)(node, dottedFieldPath);
}
/**
 * Given dotted field selector (e.g. `foo.bar`) returns a plain list of values matching this selector.
 * It is possible that the path maps to several values when one of the intermediate values is an array.
 *
 * Example node:
 * {
 *   foo: [{ bar: `bar1`}, { bar: `bar2` }]
 * }
 *
 * In this case resolveFieldValue([`foo`, `bar`], node) returns [`bar1`, `bar2`]
 *
 * When `resolvedNodeFields` argument is passed the function first looks for values in this object
 * and only looks in the node if the value is not found in `resolvedNodeFields`
 */
Given dotted field selector  returns a plain list of values matching this selector.
It is possible that the path maps to several values when one of the intermediate values is an array.





When `resolvedNodeFields` argument is passed the function first looks for values in this object
and only looks in the node if the value is not found in `resolvedNodeFields`
Given dotted field selector returns a plain list of values matching this selector . It is possible that the path maps to several values when one of the intermediate values is an array . When ` resolvedNodeFields ` argument is passed the function first looks for values in this object and only looks in the node if the value is not found in ` resolvedNodeFields `
function resolveFieldValue(dottedFieldPath, nodeOrThunk, resolvedNodeFields) {
  let result;
  if (resolvedNodeFields) {
    result = (0, _getValueAt.getValueAt)(resolvedNodeFields, dottedFieldPath);
  }
  if (typeof result !== `undefined`) {
    return result;
  }
  const node = typeof nodeOrThunk === `function` ? nodeOrThunk() : nodeOrThunk;
  return (0, _getValueAt.getValueAt)(node, dottedFieldPath);
}
function resolveFieldValue ( dottedFieldPath , nodeOrThunk , resolvedNodeFields ) { let result ; if ( resolvedNodeFields ) { result = ( 0 , _getValueAt . getValueAt ) ( resolvedNodeFields , dottedFieldPath ) ; } if ( typeof result !== ` ` ) { return result ; } const node = typeof nodeOrThunk === ` ` ? nodeOrThunk ( ) : nodeOrThunk ; return ( 0 , _getValueAt . getValueAt ) ( node , dottedFieldPath ) ; }
Given dotted field selector (e.g.
Given dotted field selector ( e . g .