Documentation

The client

v2 · Stable

Build the client

1. Supply the React entry

Write /src/frontend.tsx with the default component the React frontend contract requires. Use only the supported modules.

Done when the client bundles and mounts in the game preview.

2. Read the match

Use Read match state to obtain the board, players, and legal actions. Handle loading and spectator states.

Done when each viewer sees the correct board and a missing seat does not crash the client.

3. Send interactions

Follow Send clicks and handle failures. Keep temporary selections in local state and handle stale IDs.

Done when successful clicks advance play and refused clicks recover correctly.

4. Check the complete experience

Inspect layout and appearance, images and sounds, and end-of-game controls. Validate and play the game at wide and phone sizes.

Done when a player can start, finish, and leave the game using the client.

Need a hand with this?

Join our Discord