2
0
Эх сурвалжийг харах

load PageContents statically

Yuki Takei 3 жил өмнө
parent
commit
92ef294fa6

+ 11 - 8
packages/app/src/components/Page/PageView.tsx

@@ -17,6 +17,8 @@ import type { PageSideContentsProps } from '../PageSideContents';
 import { UserInfo } from '../User/UserInfo';
 import { UserInfo } from '../User/UserInfo';
 import type { UsersHomePageFooterProps } from '../UsersHomePageFooter';
 import type { UsersHomePageFooterProps } from '../UsersHomePageFooter';
 
 
+import { PageContents } from './PageContents';
+
 import styles from './PageView.module.scss';
 import styles from './PageView.module.scss';
 
 
 
 
@@ -95,14 +97,15 @@ export const PageView = (props: Props): JSX.Element => {
 
 
   const contents = specialContents != null
   const contents = specialContents != null
     ? <></>
     ? <></>
-    : (() => {
-      const PageContents = dynamic(() => import('./PageContents').then(mod => mod.PageContents), {
-        ssr: false,
-        // TODO: show SSR body
-        // loading: () => ssrBody ?? <></>,
-      });
-      return <PageContents />;
-    })();
+    // TODO: show SSR body
+    // : (() => {
+    //   const PageContents = dynamic(() => import('./PageContents').then(mod => mod.PageContents), {
+    //     ssr: false,
+    //     // loading: () => ssrBody ?? <></>,
+    //   });
+    //   return <PageContents />;
+    // })();
+    : <PageContents />;
 
 
   return (
   return (
     <MainPane
     <MainPane