@redwood.dev/react documentation
@redwood.dev/client documentation
Table of contents
- Obtain the Redwood binary
- Run Redwood
- Create a state tree
- Start the frontend dev server
- Going to production
- Chat with friends over the P2P network
Download binary from Github
Binaries are available for all platforms (Mac, Linux, Windows) at https://github.com/redwood/redwood/releases
Build from source
Requires Go 1.18. See the following resources to install Go:
$ git clone https://github.com/redwood/redwood
$ cd redwood/embed
$ yarn && yarn build
$ cd ../cmd/redwood
$ go build .
$ redwood -p password.txt -c .redwoodrc
$ node setup.js
As you develop your application, you can modify this script just as you would modify a traditional database migration.
$ yarn && yarn start
Once you have a stable build of your application, you can upload your assets directly to the Redwood node, which will serve them like any other web server.
Build the application:
$ yarn build
Run the provided upload-assets.js
script:
$ node upload-assets.js
And navigate to http://localhost:8080.
After uploading your assets to your node, you and your friends can chat with one another over the peer-to-peer network managed by the node.
Your friends will simply need to:
- Download (or build) Redwood
- Run it (they can use the
.redwoodrc
config file from this repository, although the default Redwood config should work equally well) - Once Redwood is started, ask your friends to run the following command in the Redwood console:
tree subscribe example.project/foo
- All of the nodes will begin syncing. After a few moments, your friends will be able to navigate to http://localhost:8080 to chat with you.