Skip to content

Commit 37f1756

Browse files
committed
fixup readme
1 parent a8affba commit 37f1756

File tree

1 file changed

+7
-9
lines changed

1 file changed

+7
-9
lines changed

browser-chat/README.md

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
# browser-chat
22

3-
This is a chat app that runs in both the browser and the command line. It uses [`iroh-gossip`](https://github.com/n0-computer/iroh-gossip/).
3+
This is a chat app that runs in both the browser and the command line. It uses [`iroh-gossip`](https://github.com/n0-computer/iroh-gossip/) to send messages between peers sharing a channel.
44

55
The example has the following parts:
66

7-
* [`shared`](shared) is a Rust library that exposes a `ChatNode`, which uses iroh and iroh-gossip to power a simple ephemeral gossip chat between peers.
8-
* [`cli`](cli) uses the `shared` library to create a basic command-line interface to chat with peers
9-
* [`browser-wasm`](browser-wasm) is a WebAssembly wrapper around the shared library which uses [`wasm-bindgen`](https://github.com/rustwasm/wasm-bindgen) to expose the chat node to JavaScript running in web browser. It can be packaged with [`wasm-pack`](https://rustwasm.github.io/wasm-pack/) into a NPM package.
10-
* [`frontend`](frontend) is a web app that uses `browser-wasm`. The web app is a single-page application written [Typescript](https://www.typescriptlang.org/), using [React](https://react.dev/) and [shadcn components](https://ui.shadcn.com/).
11-
It is built and bundled with [Vite](https://vite.dev/). The UI was initially mostly written by an AI tool, which we then adapted to use the API exposed by `browser-wasm`.
7+
* [**shared**](shared) is a Rust library that exposes a `ChatNode`, which uses iroh and iroh-gossip to power a simple ephemeral gossip chat between peers.
8+
* [**cli**](cli) uses that library to create a simple command-line chat app.
9+
* [**browser-wasm**](browser-wasm) is a wrapper around the shared library that uses [`wasm-bindgen`](https://github.com/rustwasm/wasm-bindgen) to export JavaScript bindings.
10+
* [**frontend**](frontend) is the web app. It is written in [TypeScript](https://www.typescriptlang.org/) and uses [React](https://react.dev/) and [shadcn components](https://ui.shadcn.com/).
11+
It is built and bundled with [Vite](https://vite.dev/).
1212

13-
## Browser app
13+
## Web app
1414

1515
Follow the steps below to build and run the browser version of the chat app.
1616

@@ -26,8 +26,6 @@ cargo binstall wasm-bindgen wasm-pack
2626

2727
### Building for development
2828

29-
To run the example, first build the Wasm library:
30-
3129
To build the chat app in development mode, run these commands:
3230
```
3331
cd frontend

0 commit comments

Comments
 (0)