Cordova iOS location message

后端 未结 5 1836
忘了有多久
忘了有多久 2020-12-19 01:37

I use the plugin cordova-plugin-geolocation. My only issue is that the message prompt to allow location looks like this:

/var/container/bundle/applica

5条回答
  •  半阙折子戏
    2020-12-19 02:30

    There are 3 possible reasons for displaying the path to the index.html instead of the name of your app:

    1. You have not installed the plugin (or it's not installed correctly)
    2. You are not waiting for the device ready event to call the plugin
    3. You have not linked the cordova.js file in the index.html

    As you say that you have installed the plugin and you are using it on device ready event, then it must be that you have forgotten to link the cordova.js in the index.html or the plugin wasn't installed correctly. Check that you have the cordova.js linked and if you have it, remove the plugin and add it again, removing and re adding the iOS platform might help too

提交回复
热议问题