Help understanding structure behaviior in esp now example

did you mean struct or String?

a struct is commonly used to handle IP, ethernet and other types of messages composed of various members and lengths.

it's common to pass the pointer/address of a struct along with a size to a send() which copies the memory contents at that address.

i think it's the XINU book where i might have see something like

struct Eth {
    uint8_t  dst  [6];
    uint8_t  src  [6];
    uint8_t  tag  [4];
    uint8_t  tpye [2];
    uint8_t  data [];
};

yes, data [] which ethernet buffers would be cast to to access fields and use data [] to locate the contents of the frame/packet