feat: init

This commit is contained in:
2025-09-05 15:18:10 +08:00
parent ddbee614e8
commit 85244a451e
126 changed files with 3020 additions and 10278 deletions

View File

@@ -0,0 +1,16 @@
// hooks/useDocumentTitle.js
import { useEffect } from "react";
const useDocumentTitle = (title: string) => {
useEffect(() => {
if (title) {
document.title = title;
}
// 组件卸载时可以恢复默认标题
return () => {
document.title = "默认标题"; // 或者从配置中获取
};
}, [title]);
};
export default useDocumentTitle;