From cf6ab9e9333b5f76cb9e06f6687f2b4f8fbe91bd Mon Sep 17 00:00:00 2001
From: Jacky Zhao <j.zhao2k19@gmail.com>
Date: Sun, 12 Nov 2023 22:27:53 +0000
Subject: [PATCH] feat: option to specify npx quartz sync message (closes #583)

---
 quartz/util/jsx.tsx |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/quartz/util/jsx.tsx b/quartz/util/jsx.tsx
index e813240..fc988a0 100644
--- a/quartz/util/jsx.tsx
+++ b/quartz/util/jsx.tsx
@@ -1,4 +1,4 @@
-import { Components, toJsxRuntime } from "hast-util-to-jsx-runtime"
+import { Components, Jsx, toJsxRuntime } from "hast-util-to-jsx-runtime"
 import { QuartzPluginData } from "../plugins/vfile"
 import { Node, Root } from "hast"
 import { Fragment, jsx, jsxs } from "preact/jsx-runtime"
@@ -15,11 +15,10 @@
 
 export function htmlToJsx(fp: FilePath, tree: Node<QuartzPluginData>) {
   try {
-    // @ts-ignore (preact makes it angry)
     return toJsxRuntime(tree as Root, {
       Fragment,
-      jsx,
-      jsxs,
+      jsx: jsx as Jsx,
+      jsxs: jsxs as Jsx,
       elementAttributeNameCase: "html",
       components: customComponents,
     })

--
Gitblit v1.10.0