Skip to content

Instantly share code, notes, and snippets.

@anttti
Created April 2, 2013 06:12
Show Gist options
  • Save anttti/5290251 to your computer and use it in GitHub Desktop.
Save anttti/5290251 to your computer and use it in GitHub Desktop.
var foo = {};
navigator.geolocation.getCurrentPosition(function(position) {
performFancyStuff(position, foo);
}, function(error) {
alert('Error occurred. Error code: ' + error.code);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment