Demonstrating routing with path finding algorithms using Neo4j graph database and data from OpenStreetMap.
Set environment variables:
REACT_APP_NEO4J_URI=XXX
REACT_APP_NEO4J_USER=XXX
REACT_APP_NEO4J_PASSWORD=XXX
REACT_APP_MAPBOX_TOKEN=XXX
these can be added to .env
Clone this git repo, and then
This project is composed of a simple React web app and a GraphQL API created using neo4j-graphql.js. In addition, a Neo4j database with OpenStreetMap data is required.
- Prepare the Neo4j database by importing OpenStreetMap data and extract the routing graph using this library.
TODO: example for POT / routing graph extract.
- Ensure each
PointOfInterestnode has apoi_idproperty set:
MATCH (a:PointOfInterest)
WITH a,a.name + toString(a.location.latitude) + toString(a.location.longitude) AS poi
SET a.poi_id = poi
- Install APOC and Graph Algorithms database plugins.
