优化页头样式与操控 & 优化首页推荐文章部分 & 修复后台未正确流式加载问题
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import {ReactNode} from 'react'
|
||||
import {ReactNode, Suspense} from 'react'
|
||||
import {Metadata} from 'next'
|
||||
|
||||
export async function generateMetadata(): Promise<Metadata> {
|
||||
@@ -12,5 +12,9 @@ export type BillsLayoutProps = {
|
||||
}
|
||||
|
||||
export default async function BillsLayout(props: BillsLayoutProps) {
|
||||
return props.children
|
||||
return (
|
||||
<Suspense>
|
||||
{props.children}
|
||||
</Suspense>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@ export default async function DashboardPage(props: DashboardPageProps) {
|
||||
if (!resp.success) {
|
||||
return (
|
||||
<div className="col-start-4 row-start-3 row-span-2 flex justify-center items-center">
|
||||
获取公告数据失败
|
||||
初始化数据失败
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user