备份:修复前完整项目快照 2026-04-19

This commit is contained in:
root
2026-04-19 19:15:01 +08:00
parent 5266d7732b
commit d00f41a120
449 changed files with 89577 additions and 23251 deletions
+31
View File
@@ -0,0 +1,31 @@
import React, { useEffect } from 'react';
const TestPage2: React.FC = () => {
console.log('TestPage2组件被渲染了');
useEffect(() => {
console.log('TestPage2组件挂载了');
// 测试API调用
const testApi = async () => {
try {
console.log('开始测试API调用...');
const response = await fetch('/api/users');
console.log('响应状态:', response.status);
const data = await response.json();
console.log('API返回数据:', data);
} catch (error) {
console.error('API调用失败:', error);
}
};
testApi();
}, []);
return (
<div style={{ padding: 24 }}>
<h1></h1>
<p>console.log是否正常工作</p>
</div>
);
};
export default TestPage2;