chore: code style
This commit is contained in:
+12
-9
@@ -1,13 +1,16 @@
|
|||||||
import { PropsWithChildren, Suspense } from 'react';
|
import { ReactNode, Suspense, FC } from "react";
|
||||||
import Loading from "../common/component/Loading";
|
import Loading from "../common/component/Loading";
|
||||||
type Props = {}
|
|
||||||
|
|
||||||
const Lazy = ({ children }: PropsWithChildren<Props>) => {
|
type Props = {
|
||||||
return (
|
children?: ReactNode;
|
||||||
<Suspense fallback={<Loading />}>
|
}
|
||||||
{children}
|
|
||||||
</Suspense>
|
const Lazy: FC<Props> = ({ children }) => {
|
||||||
);
|
return (
|
||||||
|
<Suspense fallback={<Loading />}>
|
||||||
|
{children}
|
||||||
|
</Suspense>
|
||||||
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
export default Lazy;
|
export default Lazy;
|
||||||
|
|||||||
Reference in New Issue
Block a user