Introducing the Holochain Playground

I just updated it with a designer mode, intended for designers and developers to specify what is in the entries of the app and how they relate with one another.

There are a couple UX issues, I want to fix them soon. Let me know what you think and if you have any feedback!

1 Like

It’s awesome, good job! I just did my first contribution, it’s very small in terms of code but I think important for the UX: https://github.com/holochain-open-dev/holochain-playground/pull/1

Awesome, merged :slight_smile: thanks!

1 Like

Unfortunately, I think that might have broken something? Just me perhaps?

Not just you, it seems this little guy persists… You can click one entry to reposition everything as a workaround until I push a fix

Should be fixed now, let me know if this persists.

1 Like

It works better but i can still notice some errors in the console when i click upon the nodes: Uncaught (in promise) TypeError: Cannot read property ‘x1’ of undefined

Thanks, yes I know, it’s a weird glitch but doesn’t affect the UI, so low prio for now.

Oh wow @guillemcordoba, this is really neat. I’ve done just a bit of messing around and it’s really useful to understand how it works! Great for newcomers, I wager!

Glad you like it! Give me any feedback as far as understanding what is doing what goes! Would you have liked some more explanation about a specific topic/functionality?

Sure! I’m a bit of a newbie when it comes to Holochain but it is an awesome visual representation of the core functionalities. I personally like the technical view with the DHT shard and source chain to see how it actually evolves over time.

I recently came across anchors (and all that jazz about anchor trees). I don’t think you should be focusing on it because it’s just a tiny detail and it’s, after all, a pattern rather than core functionality but I think it’d be interesting to see a way to actually create anchors and link entries to these and see this progress play out in the source chain and DHT (visually).

But that’s nitpicking! I think it’s a really interesting idea and well implemented. Huge props! I might mess around with the source code to help whenever I can (I’m still a newbie tho :stuck_out_tongue:)

Hum okey! You can create anything you want in the playground right now, including anchors. This would look something like:

  1. Create an anchor entry, with these contents: {"anchor_type": "username", "anchor_text": "guillemcordoba"}
  2. Get the address of that entry, and an address for any agentId entry, and link them together.

You can repeat this process any number of times to see what the anchor linked to multiple entries would look like. Maybe this is easier to do in designer mode.

1 Like

Oh yeah, you’re right. Completely missed you could actually link entries. My immediate reaction is to go into technical mode so it gets a bit hard to link entries together because I ought to save the address of both the anchor and the entry and the state isn’t saved when changing between the Source Chain and the tab to create entries. Yeah, you’re right, I can see linking in designer mode better, shows the arrow perfectly!

Perhaps I need to mess around more to actually find any problems because I’ve yet to stumble upon any haha

1 Like

Hi everyone, just updated the playground with the ability to connect to real holochain nodes! You can use this when you are developing to see your entry graph updated in real time.

Feedback is appreciated as always!

4 Likes

You are on fire there @guillemcordoba, so fun to see you rock this space! :slight_smile:

2 Likes

Thanks @ViktorZaunders, it’s very fun and rewarding to do this kind of side-projects as well :slight_smile:

This is also distributed as a custom element in the form of a NPM package: https://www.npmjs.com/package/holochain-playground. With this you can basically include the playground in any web application.

2 Likes

I’m gonna try some visual feedback let me know whether it works.

1 Like

Okey that’s great, you can input whatever string you want as your entry type. But it’s great to see the feedback, thanks :slight_smile:

Would a help dialog in the commit entries panel help?

1 Like

I think a help dialogue would help, yes!