From 6ea359e55ee6333f27b0a8d59caebdb17b9acbf0 Mon Sep 17 00:00:00 2001
From: Jacky Zhao <j.zhao2k19@gmail.com>
Date: Sun, 15 Sep 2024 23:42:07 +0000
Subject: [PATCH] perf: have more than 1ms granularity for rebuild detection
---
quartz/components/Body.tsx | 13 +++++--------
1 files changed, 5 insertions(+), 8 deletions(-)
diff --git a/quartz/components/Body.tsx b/quartz/components/Body.tsx
index 6b1f234..96b6278 100644
--- a/quartz/components/Body.tsx
+++ b/quartz/components/Body.tsx
@@ -1,16 +1,13 @@
// @ts-ignore
-import clipboardScript from './scripts/clipboard.inline'
-import clipboardStyle from './styles/clipboard.scss'
-import { QuartzComponentConstructor, QuartzComponentProps } from "./types"
+import clipboardScript from "./scripts/clipboard.inline"
+import clipboardStyle from "./styles/clipboard.scss"
+import { QuartzComponent, QuartzComponentConstructor, QuartzComponentProps } from "./types"
-function Body({ children }: QuartzComponentProps) {
- return <div id="quartz-body">
- {children}
- </div>
+const Body: QuartzComponent = ({ children }: QuartzComponentProps) => {
+ return <div id="quartz-body">{children}</div>
}
Body.afterDOMLoaded = clipboardScript
Body.css = clipboardStyle
export default (() => Body) satisfies QuartzComponentConstructor
-
--
Gitblit v1.10.0