Skip to content

A todo sample app for Holochain RSM that integrates GraphQL functionality on the conductor (server) level.

License

Notifications You must be signed in to change notification settings

kristoferlund/hc-graphql-todo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Holochain / GraphQL Todo Sample

This app was built to test integrating Holochain with the Juniper GraphQL server library for Rust. Conclusion: It works great! No obvious performance loss or excessive memory consumption, even though that would have to be investigated more in detail. Juniper adds only ca 150 K to the final size of compiled DNA. Client development becomes really straightforward when Holochain can be acessed as a GraphQL endpoint.

vid

DNA

The DNA accepts queries on a single endpoint: graphql. See file schema.graphql for available queries/mutations.

Client

The client is built on React / Material UI and uses Apollo Client / Holochain Conductor API to communicate with Holochain.

Requirements

  • Having run through holochain RSM installation.
  • Run all the steps described in this README.md inside the nix-shell of the holochain core repository.
  • Have holochain-run-dna installed globally, and the lair-keystore described in its README as well.

Docs

To generate the Zome API docs:

cd dna
cargo doc --open

Building

cd dna
sh build.sh

Testing

After having built the DNA:

cd dna/tests
npm install
npm test

Run Holochain with DNA

After having built the DNA:

cd dna
sh run.sh

Now holochain will be listening at port 8888;

Restart the command if it fails (flaky holochain start).

Run client

cd client
yarn
yarn start

Contributing

Yes, please! Raise an issue or post a pull request.

License

MIT

About

A todo sample app for Holochain RSM that integrates GraphQL functionality on the conductor (server) level.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published