mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-07-02 00:23:57 -05:00
Enable erasableSyntaxOnly TS flag
This commit is contained in:
parent
7011dcb370
commit
9693f867bc
|
|
@ -2,11 +2,12 @@ import { useFetcher } from "@remix-run/react";
|
|||
import { type ReactNode, useCallback } from "react";
|
||||
import { createContext, useContext, useEffect, useState } from "react";
|
||||
|
||||
enum Theme {
|
||||
DARK = "dark",
|
||||
LIGHT = "light",
|
||||
}
|
||||
const themes: Array<Theme> = Object.values(Theme);
|
||||
const Theme = {
|
||||
DARK: "dark",
|
||||
LIGHT: "light",
|
||||
} as const;
|
||||
type Theme = (typeof Theme)[keyof typeof Theme];
|
||||
const themes = Object.values(Theme);
|
||||
|
||||
type ThemeContextType = {
|
||||
/** The CSS class to attach to the `html` tag */
|
||||
|
|
|
|||
|
|
@ -7,22 +7,23 @@ import type { Result } from "./unions";
|
|||
/**
|
||||
* The possible status for a match.
|
||||
*/
|
||||
export enum Status {
|
||||
export const Status = {
|
||||
/** The two matches leading to this one are not completed yet. */
|
||||
Locked = 0,
|
||||
Locked: 0,
|
||||
|
||||
/** One participant is ready and waiting for the other one. */
|
||||
Waiting = 1,
|
||||
Waiting: 1,
|
||||
|
||||
/** Both participants are ready to start. */
|
||||
Ready = 2,
|
||||
Ready: 2,
|
||||
|
||||
/** The match is running. */
|
||||
Running = 3,
|
||||
Running: 3,
|
||||
|
||||
/** The match is completed. */
|
||||
Completed = 4,
|
||||
}
|
||||
Completed: 4,
|
||||
};
|
||||
export type Status = (typeof Status)[keyof typeof Status];
|
||||
|
||||
/**
|
||||
* The results of a participant in a match.
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
"lib": ["DOM", "DOM.Iterable", "es2024"],
|
||||
"module": "ESNext",
|
||||
"isolatedModules": true,
|
||||
"erasableSyntaxOnly": true,
|
||||
"esModuleInterop": true,
|
||||
"jsx": "react-jsx",
|
||||
"moduleResolution": "Bundler",
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user