API - field key data option

0 votes
167 views
added Jun 28, 2021 in API by lcjr First Warrant Officer (11,830 points)
// const carpark = data?.result?.field_prop_car_parking ?? ''; 
// if the above is not working, try the following one, due to path structure

  const carpark = data?.result?.field_prop_car_parking?.und?.[0]?.value ?? '';

 

lazacode.org - Malaysia's programming knowledge sharing platform, where everyone can share their finding as reference to others.
...