Reference · Shared Awase table
seatNamefunction
What a seat is called: its name, "Computer 2", or its wind.
Import it
import { seatName } from "@johnmorrisdotca/jarajara/table";
Definition
function seatName(seats: readonly AwaseSeat[], at: number): string
Parameters
| Name | Type | Description |
|---|---|---|
seats | readonly AwaseSeat[] | The two to four local player names and optional computer flags. |
at | number | The supplied time in milliseconds, or the zero-based seat index specified by the signature. |
Returns
string
What a seat is called: its name, "Computer 2", or its wind.
Examples
import { seatName } from "@johnmorrisdotca/jarajara/table";
console.log(seatName([{name:"Seat 1"},{name:"Seat 2"}],0));Seat 1What it prints (run when this page was built)