Skip to content
This repository has been archived by the owner on Nov 7, 2024. It is now read-only.

Commit

Permalink
Basic my notifications element working
Browse files Browse the repository at this point in the history
  • Loading branch information
guillemcordoba committed Apr 29, 2024
1 parent 16d19ce commit 1d7a094
Show file tree
Hide file tree
Showing 20 changed files with 1,256 additions and 1,360 deletions.
1,446 changes: 553 additions & 893 deletions Cargo.lock

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ members = ["zomes/coordinator/*", "zomes/integrity/*"]
resolver = "2"

[workspace.dependencies]
holochain = { version = "=0.3.0-beta-dev.45", default-features = false, features = [
holochain = { version = "0.3.0-beta-dev.48", default-features = false, features = [
"test_utils",
] }
hdi = "=0.4.0-beta-dev.34"
hdk = "=0.3.0-beta-dev.38"
hdi = "0.4.0-beta-dev.36"
hdk = "0.3.0-beta-dev.41"
serde = "1.0.193"

2 changes: 1 addition & 1 deletion docs/notifications-store.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ import { NotificationsStore, NotificationsClient } from "@darksoil-studio/notifi
const store = new NotificationsStore(new NotificationsClient(appAgentClient, 'my-role-name'));
```

> Learn how to setup the `AppAgentClient` object [here](https://www.npmjs.com/package/@holochain/client).
> Learn how to setup the `AppClient` object [here](https://www.npmjs.com/package/@holochain/client).
Learn more about the stores and how to integrate them in different frameworks [here](https://holochain-open-dev.github.io/reusable-modules/frontend/using/#stores).
6 changes: 3 additions & 3 deletions docs/setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@ This will do the following:

Now you only need to integrate the zome's frontend in your web-app.

2. Connect to Holochain with the `AppAgentClient`, and create the `NotificationsStore` with it:
2. Connect to Holochain with the `AppClient`, and create the `NotificationsStore` with it:

```js
import { NotificationsStore, NotificationsClient } from "@holochain-open-dev/profiles";
import { AppAgentWebsocket } from "@holochain/client";
import { AppWebsocket } from "@holochain/client";

async function setupNotificationsStore() {
// TODO: change "MY_APP_NAME" for the roleId that you can find in your "happ.yaml"
const client = await AppAgentWebsocket.connect('<MY_APP_NAME>')
const client = await AppWebsocket.connect('<MY_APP_NAME>')

// TODO: change "MY_CELL_ROLE" for the roleId that you can find in your "happ.yaml"
return new NotificationsStore(new NotificationsClient(client, '<MY_CELL_ROLE>'));
Expand Down
Loading

0 comments on commit 1d7a094

Please sign in to comment.