Skip to main content

FrontendLayout

Function FrontendLayout 

Source
pub fn FrontendLayout(props: FrontendLayoutProps) -> impl IntoView
Expand description

前台整体布局组件。

负责渲染 Header(含前台导航与主题切换)、主内容区与 Footer。 骨架屏分两处:懒加载分包挂起时(路由器仍显示旧页面)由 main 顶部的 .route-pending 槽位占位目标页骨架,显隐跟随协调器的 is-route-pending;页面挂载后的数据读取由 Suspense 兜底显示。

Props:

  • children:显式传入的页面内容(未匹配路由的 404 兜底用);缺省渲染嵌套路由的 <Outlet/>

§Optional Props

  • children: [ChildrenFn]