With React Together, you can easily add real-time multi-user interaction to any React app.
No backend or net-code required!
React Together provides a series of hooks that synchronize state across multiple clients. This allows to build any component you want, such as real-time chat, live cursors and polls, multiplayer games, etc. It also provides a series of pre-built components to help you get started.
npm install react-together
The snippet below shows you how easy it is to create a synchronized counter.
import { useStateTogether } from 'react-together'
export function SynchronizedCounter() {
const [value, setValue] = useStateTogether('counter', false)
return <button onClick={() => setValue((p) => p + 1)}>{value}</button>
}
Ready to start using React Together? Check out our Getting Started guide.
Join our active Discord community to get involved with the project, get close support, and share what you're building.
Get up to date with the latest news and announcements.
Let's build React Together... together!!
We warmly invite contributions from everyone. Before you get started, please take a moment to review our Contributing Guide. Feel free to share your ideas through Pull Requests or GitHub Issues. Enjoy your coding journey! :)
To run and test React Together locally, run the following commands:
$ git clone git@github.com:multisynq/react-together.git
$ cd react-together
$ npm install
$ npm run build
$ npm run website # This will start the website
$ npm run playground # This will start the playground
Open your browser and visit http://localhost:5173.
Licensed under the Apache License 2.0, Copyright © 2024-present Croquet Labs.
See LICENSE for more information.