feat(rg): parallelize
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
"use client";
|
||||
|
||||
import type { MaybePromise } from "bun";
|
||||
import { use, type ReactNode } from "react";
|
||||
|
||||
export function Conditional({
|
||||
children,
|
||||
c,
|
||||
}: {
|
||||
children: ReactNode;
|
||||
c: MaybePromise<any>;
|
||||
}) {
|
||||
const val = use(c);
|
||||
return !!val && children;
|
||||
}
|
||||
Reference in New Issue
Block a user