Skip to content

multisynq/react-together

Repository files navigation

React Together

With React Together, you can easily add real-time multi-user interaction to any React app.

No backend or net-code required!

NPM version NPM downloads NPM size

Join Discord Follow Twitter

Changelog · Report Bug · Request Feature

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.

📦 Installation

npm install react-together

🔨 Usage

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.

🫂 Community

Join Discord

Join our active Discord community to get involved with the project, get close support, and share what you're building.


Follow Twitter

Get up to date with the latest news and announcements.


🔗 Useful Links

🤝 Contributing PRs Welcome

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! :)

⌨️ Local Development

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.

License

Licensed under the Apache License 2.0, Copyright © 2024-present Croquet Labs.

See LICENSE for more information.

About

Synchronized React Components without any server code

Topics

Resources

License

Stars

31 stars

Watchers

7 watching

Forks

Packages

 
 
 

Contributors