An extreme fast and highly scalable Firebase geo-query library.
npm install gofgeo on fire (gof) :fire:




===========
Geo on fire is an open source library to query location based data in Firebase. It follows a whole new principle of architecture, which makes it extremly fast and highly scaleable. With the right setup you are able to query millions of locations in just fractions of a second. You can learn more about the principle in the advanced usage guide. (not online so far, stay tuned)
In addition it offers you the possibility to listen to the queries in real time and recieve changes based on the event types you've specified. But that's not all. There's a feature which gives you the ability to priorize data and make the user expirience even better.
And by the way, there is not just one query method. You can choose between a radius based query (see dog match demo) and a boundaries based query. (see event map demo)
And the best, you will automatically recieve the fetched entries. So there is no manual fetching needed.
* Download
* Getting started
* Guides
* Documentation
* Demos
* Contributions
* License
> Notice: NodeJS is not supported so far, but it will be added soon. Subscribe here to get mentioned when the time is ready.
Add it like this to your HTML
``html`
or install it from npm
`bash`
$ npm install firebase --save
`html`
bash
$ npm install gof --save
`
$3
Or download it from bower the following way:
`bash
$ bower install gof --save
`Getting started
Now let's get started. As you will see, the usage is very simple. Before you're able to use gof you need to initialize your firebase project.
`js
var fb = firebase.initializeApp(config); // get 'config' from firebase
`Now you are able to create a gof reference by simply doing the following.
`js
// the name of your database nodes e.g. events, hotels - is totally up to you
var name = 'entries'; // the firebase database ref - must be passed with the .ref()
var ref = fb.database().ref();
// creates a new geoOnFire instance
var gof = new geoOnFire(name, ref);
``That's it! Now you are able to run gof operations. Go trough the guides to see how it works.
#### writing data
* create entries
* update entries
* delete entries
#### reading data (geolocation queries)
* query by radius
* query by boundaries
Is there any gof using project you want to share with the world? Simply create an issue with the url and I do the rest.
I'm also looking forward to migrate the library to other db services like mongoDB or pouchDB.