diff --git a/CHANGELOG.md b/CHANGELOG.md index d803588b37..6037082cb2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Changed + +- Examples: Add Relay JavaScript example. + ## [0.19.2] - 2022-03-21 ### Fixed diff --git a/examples/README.md b/examples/README.md index a41a7eb81e..d7b29cc990 100644 --- a/examples/README.md +++ b/examples/README.md @@ -13,5 +13,6 @@ Here is the list of the code examples and the features they demonstrate: No async/await syntax. - [Minimal ReactJS Waku Store App](store-reactjs-chat): Waku Store, React/JavaScript, Protobuf using `protons`. - [Using Waku Store in JavaScript](store-js): Stop retrieving results from Waku Store on condition, Use minified bundle from Unpkg.com, JavaScript. +- [Using Waku Relay in JavaScript](relay-js): Receive and send text messages with Waku Relay, Use minified bundle from Unpkg.com, JavaScript. See https://docs.wakuconnect.dev/docs/examples/ for more examples. diff --git a/examples/relay-js/README.md b/examples/relay-js/README.md new file mode 100644 index 0000000000..c972622886 --- /dev/null +++ b/examples/relay-js/README.md @@ -0,0 +1,11 @@ +# Using Waku Relay in JavaScript + +**Demonstrates**: + +- Waku Relay: Send and receive messages using Waku Relay. +- Pure Javascript/HTML. +- Use minified bundle of js from unpkg.com, no import, no package manager. + +This example uses Waku Relay to send and receive simple text messages. + +To test the example, simply download the `index.html` file from this folder and open it in a browser. diff --git a/examples/relay-js/index.html b/examples/relay-js/index.html new file mode 100644 index 0000000000..b39276d53a --- /dev/null +++ b/examples/relay-js/index.html @@ -0,0 +1,163 @@ + + + + + + + JS-Waku Chat + + + + +

Waku Node Status

+
+ + + + +

Messages

+
+ + + + + + +