Ability to have non-grid layouts

Hello,

Check out my commit and tell me what you think.

Your A* is great but was limited to a grid layout. I've added the ability to handle other layouts, such as a graph of cities.

- Extract grid specifities into the Graph function
- Extract heurstics functions into a specific object
- Update tests, benchmark & demo
- Added a specific test to demonstrate usage and gps heuristic
Please use `var node =` here instead of a single var at the top of the function (matches convention throughout the file)