UseWindowTitle
Last updated: 3.0.0 (04/07/2024)
Usage
import { UseWindowTitle, Text } from "@valence-ui/core";
function MyComponent() {
UseWindowTitle("My Page Title");
return (
<Text>
Check the browser tab!
</Text>
)
}Dynamic titles
import { UseWindowTitle, Text } from "@valence-ui/core";
import { useState } from "react";
function MyComponent() {
const [count, setCount] = useState(0);
UseWindowTitle(`Count: ${count}`);
return (
<Text>
The tab title shows the current count!
</Text>
)
}Page-specific titles
Parameters
Parameter
Type
Description
Last updated