This allows for localStorage-based switching to a websocket-based implementation for multiplayer.
Websockets, while requiring a dedicated backend service, easily allow for >2 players without complicated additional logic. It also is a more well-documented and supported transport mechanism.
The related backend server code can be found at https://github.com/erlloyd/cardtable-multiplayer-server. The goal of that service is still not to store any state, but just be a passthrough to pass state changes to connected clients.
This allows for localStorage-based switching to a websocket-based implementation for multiplayer.
Websockets, while requiring a dedicated backend service, easily allow for >2 players without complicated additional logic. It also is a more well-documented and supported transport mechanism.
The related backend server code can be found at https://github.com/erlloyd/cardtable-multiplayer-server. The goal of that service is still not to store any state, but just be a passthrough to pass state changes to connected clients.