Skip to content

Commit 9844c89

Browse files
committed
chore: add tencent cloudbase #no-ticket
1 parent a9e4662 commit 9844c89

2 files changed

Lines changed: 4 additions & 6 deletions

File tree

docs/sdk/announcements/sunset-export.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ Class](/sdk/storage/guide/rest/#遍历-class)。
6969

7070
<Conditional region="cn">
7171

72-
<h2>腾讯云 CloudBase</h2>
72+
## 腾讯云 CloudBase
7373

7474
我们推荐使用腾讯云 CloudBase 作为 LeanCloud 的替代方案。CloudBase 提供数据库、云函数、云存储、身份认证等与 LeanCloud
7575
类似的能力,并配备完整迁移指南及智能迁移脚本,支持自动数据格式转换。

src/docComponents/conditional.tsx

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,21 @@
11
import { BRAND, REGION } from "../constants/env";
2+
import React, { type ReactNode } from "react";
23

34
interface ConditionalProps {
4-
children: React.ReactElement[];
5+
children?: ReactNode;
56
brand?: string;
67
region?: string;
78
if?: boolean;
89
}
910

1011
export function Conditional(props: ConditionalProps) {
11-
12-
13-
1412
const { children, brand, region } = props;
1513
if (
1614
(!brand || brand === BRAND) &&
1715
(!region || region === REGION) &&
1816
(props.if === undefined || props.if)
1917
) {
20-
return children;
18+
return <>{children}</>;
2119
} else {
2220
return null;
2321
}

0 commit comments

Comments
 (0)