It is a practice project to create a CRUD application with React front end, Apollo and GraphQL to connect to Neo4j database.
Followings have been the main sources:
- Apollo and GraphQL: GRANDstack.
- React implementation: Material-UI
- Dark mode: react-hook-context-emotion-dark-mode.
The aim is to have a generic client to connect to Neo4j database and automatically get Nodes
and Relationships
in a graph visualization.
Then select a Node
type and select properties
to be listed. Available properties
dynamically aligned to the selected Node
. Result table used as CRUD interface, with filter and sort functionalities.
When a line selected all properties
displayed not just the selected ones.
The detailed page has a visualization with option to increase or decrease the distance traversed.
-
Download the code and install dependencies:
npm install
or with Yarn
yarn install
-
Create a Neo4j database:
Neo4j Sandbox:
- Neo4j Sandbox instance with 'Movies' pre built option. Make sure that
.api/.env
has a line like:NEO4J_URI=bolt://18.204.14.182:33815
. - Find
username
,password
andBolt URL
under 'Connection Details' tab and copy them to./api/.env
.
Neo4j Desktop:
- Neo4j Desktop instance with 'APOC' plugin. Open 'Neo4j Browser' and run
:play movie-graph
, follow the instruction to create 'Movies' data set, for more check out Built-In Examples. Make sure that.api/.env
has the exact line:NEO4J_URI=bolt://localhost:7687
. - Use
username
,password
andBolt URL
to update./api/.env
.
Note:
.env
should not be part of public repository, it was left out from.gitignore
for easy start. - Neo4j Sandbox instance with 'Movies' pre built option. Make sure that
-
Open a new terminal and run:
npm start
or with Yarn
yarn start