Fix page titles
This commit is contained in:
BIN
src/favicon.png
BIN
src/favicon.png
Binary file not shown.
|
Before Width: | Height: | Size: 2.1 KiB |
@@ -2,8 +2,8 @@ import { useEffect } from "react";
|
||||
|
||||
export function usePageTitle(title) {
|
||||
useEffect(() => {
|
||||
document.title = title
|
||||
? `${import.meta.env.VITE_PRODUCT_NAME} | ${title}`
|
||||
: import.meta.env.VITE_PRODUCT_NAME;
|
||||
const productName =
|
||||
import.meta.env.VITE_PRODUCT_NAME || "Matrix Video Chat";
|
||||
document.title = title ? `${productName} | ${title}` : productName;
|
||||
}, [title]);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user