Cordova-google-map plugin reverse geocoding always not found

following example using cordova googlemaps plugin reverse geocoding, i always get not found, but when the latLng test in Google map there is retun address.

here is part of code i use :

searchLocation(data){ 

 // data contain latLng from other function and tested has correct value

      plugin.google.maps.Geocoder.geocode({
        "position": data
      }, (results) => {
        
        if (results.length === 0) {
          // Not found
          return;
        }
        let address = [
          results[0].subThoroughfare || "",
          results[0].thoroughfare || "",
          results[0].locality || "",
          results[0].adminArea || "",
          results[0].postalCode || "",
          results[0].country || ""].join(", ");
          
          this.presentToast('Location address :'+ address);
         // marker.setTitle(address)
         //       .showInfoWindow();
      });
  }

“cordova-plugin-googlemaps”: “^2.2.5”,

ionic info :

@ionic/cli-utils : 1.19.1
ionic (Ionic CLI) : 3.19.1

global packages:

cordova (Cordova CLI) : not installed

local packages:

@ionic/app-scripts : 3.1.8
Cordova Platforms  : android 6.3.0
Ionic Framework    : ionic-angular 3.9.2

System:

Android SDK Tools : 26.1.1
Node              : v8.9.4
npm               : 5.6.0
OS                : Windows 10

thank you

did u install this? via npm as well as cordova?

try use this
https://ionicframework.com/docs/native/native-geocoder/

Inside the native is almost the same code.

i have try the code with on Map click event , i can get the address,
when i try using camera move end it doesnt work. so i want to figure out, why this event cant get address and always return not found event though lat lng alreday there.

thank you

Please share your project files on GitHub

thank you for trying to help

Please share the project files as ionic project file structure.

structure

i just try new project from ionic start and add page

This is your wrong point.

let latLng = cameraPosition.target.lat + ',' + cameraPosition.target.lng;
// reverse geocode to get address
plugin.google.maps.Geocoder.geocode({
      "position": latLng
}, function (results) {

You need to pass {lat: ..., lng: ...} JSONObject.

So, this is enough.

// reverse geocode to get address
plugin.google.maps.Geocoder.geocode({
      "position": cameraPosition.target
}, function (results) {

i am sure already did that some times. i event try to hard code lat lng.
i will double check that again
thank you