An open API service indexing awesome lists of open source software.

https://github.com/useallfive/current-location

JavaScript helper for getting current location in browser and dealing with the response.
https://github.com/useallfive/current-location

Last synced: 12 months ago
JSON representation

JavaScript helper for getting current location in browser and dealing with the response.

Awesome Lists containing this project

README

          

# Documentation

## Example usage

```javascript
window.currentLocation.init({
"success": function(position) {
//-- Do something with position object
}
});
```

## Options

| Option | Type | Arguments | Default |
|--------------------|---------------|------------|-------------------------|
| success | function | position | log position in console |
| error | function | err | log error in console |
| enableHighAccuracy | boolean | | false |
| timeout | number | | Infinity |
| maximumAge | number | | 0 |