Skip to content

Commit 50ea068

Browse files
committed
Some delay for better UX
1 parent 15f5f21 commit 50ea068

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

src/components/Content/index.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Construction, Pickaxe } from "lucide-react";
1+
import { Pickaxe } from "lucide-react";
22
import "./style.css";
33

44
export function Content({ content, loading }) {

src/utils/api.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,10 @@ export const useApi = () => {
6262
const decoded = decodeURIComponent(escape(atob(topicData.content)));
6363
const content = unified().use(remarkParse).parse(decoded);
6464

65+
await new Promise((resolve) => {
66+
setTimeout(resolve, 1000);
67+
});
68+
6569
successCallback?.(content);
6670
return content;
6771
}, []);

0 commit comments

Comments
 (0)