(tic-tac-toe): Laid the foundations for tic tac toe/database interactions
This commit is contained in:
parent
f5c0f5635d
commit
edeee0093b
3 changed files with 4 additions and 1 deletions
|
|
@ -33,7 +33,7 @@ export const TicTacToeImpl: Omit<ITicTacToeDb, keyof Database> = {
|
|||
|
||||
export type TicTacToeId = number & { readonly __brand: unique symbol };
|
||||
|
||||
export type TemplateData = {
|
||||
export type TicTacToeData = {
|
||||
readonly id: TicTacToeId;
|
||||
readonly player1: string;
|
||||
readonly player2: string;
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ import * as auth from '@shared/auth';
|
|||
import * as swagger from '@shared/swagger';
|
||||
import * as utils from '@shared/utils';
|
||||
import { Server } from 'socket.io';
|
||||
import type { TicTacToeData } from '@shared/database/mixin/tictactoe';
|
||||
|
||||
declare const __SERVICE_NAME: string;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
import type { TicTacToeData } from '@shared/database/mixin/tictactoe';
|
||||
|
||||
// Represents the possible states of a cell on the board.
|
||||
// `null` means that the cell is empty.
|
||||
type CellState = 'O' | 'X' | null
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue