GitHub Documentation

Best practices for React integration

  • Hi,

    I wonder - is there a guide somewhere that lays out best practices to use Colyseus within a React SPA/PWA?

    There’s a lot of finicky things to consider for a medium/big game. How to handle global state, how to handle connections and reconnects, all in combination with the react lifecycle methods.

    Im currently dipping my toes in this and there’s a few things I’m not exactly sure on how to best handle going forward. It’s a turn based game and the state is going to be quite large (multiplayer strategy).

    I would be super thankful if someone who already worked on a React implementation could share their experience. I can share my experience so far but I really just scratched the surface, as I’m only just starting with gameplay after setting up devops and basic connection handling and matchmaking.

  • administrator

    Can you give your thoughts on this @Meabo, @merhawie? 👀

  • @genox I face the same challenge/problem as you. I see there wasn't much response in this topic, did you maybe come up with something along the way?


© 2021 Lucid Sight, Inc