gps - Ripple geolocation settings being ignored by Cordova application -


i'm using visual studio 2013 update 4 , i've installed visual studio cordova add-on (version 0.3.22015.1).

i have created angular based app based on ionic sidemenu starter template cordova example. have included cordova geolocation plugin in config.xml file.

within example obtaining device's location using following code:

$scope.showposition = function (position) {  // ... }  $scope.getlocation = function () {  if (navigator.geolocation) {   navigator.geolocation.getcurrentposition($scope.showposition, $scope.showerror);  }  else {   $scope.error = "geolocation not supported browser.";  } } 

when code executed i'm expecting position object passed showposition callback have mock geolocation values specified in ripple emulator. don't these mock values, actual position.

how can code use mock values?

unfortunately bug ripple itself. news fix released on wednesday. https://github.com/apache/incubator-ripple/blob/master/doc/changelog.md

you can patch ripple in vs 2013 opening command command prompt , typing:

cd %appdata%\npm\node_modules\vs-mda npm install ripple-emulator@0.9.29 --save 

for vs 2015:

cd %appdata%\npm\node_modules\vs-tac npm install ripple-emulator@0.9.29 --save 

you need again if clear cordova cache.


Comments

Popular posts from this blog

shopping cart - Page redirect not working PHP -

php - How to modify a menu to show sub-menus -

python - Installing PyDev in eclipse is failed -