getting the "business" info from address Input

Hi
Using the address input element, when writting a ‘business’ name, only the address itself is returning from the API. For instance, I start to write
empire
Auto completion suggests:
Empire State Building, West 34th Street, New-York etc
However, the address value is only West 34th Street, New-York etc
The ‘business address’ ( Empire State Building) is lost!
And for my website it is really of interest to display it with the address…
I saw a 3yo post from @robert-mccormick on that issue here but apparently with no update…
I may have missed information…
Any update in 2022?
Thank you in advance,

Hey Emmanuel

I was having difficulty with this problem too, but think I found a solution today.

If you’re still interested, see if this gets you what you’re after (adding the change event function via the gui):

export function addressInput1_change(event) {
console.log($w('#addressInput1').value.streetAddress.formattedAddressLine);
} 

I can’t believe it took me so long to find… I was already familiar with .value.formatted… :frowning:

pingu