mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-05-12 05:35:16 -05:00
* Initial * CSS lint * Test CI * Add 1v1, 2v2, and 3v3 Tags (#1771) * Initial * CSS lint * Test CI * Rename step --------- Co-authored-by: xi <104683822+ximk@users.noreply.github.com>
10 lines
287 B
TypeScript
10 lines
287 B
TypeScript
import { useEffect } from "react";
|
|
import { makeTitle } from "~/utils/strings";
|
|
|
|
/** Set title on mount. Used for showing a translated title on pages without loader. */
|
|
export function useSetTitle(title: string) {
|
|
useEffect(() => {
|
|
document.title = makeTitle(title);
|
|
}, [title]);
|
|
}
|