Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 79eb745

Browse files
committed
update
1 parent 548c3d4 commit 79eb745

File tree

2 files changed

+14
-11
lines changed

2 files changed

+14
-11
lines changed

docusaurus.config.ts

+4-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const config: Config = {
1515
favicon: 'img/favicon.ico',
1616

1717
// Set the production url of your site here
18-
url: 'https://www.uopensail.com',
18+
url: 'https://docs.uopensail.com',
1919
// Set the /<baseUrl>/ pathname under which your site is served
2020
// For GitHub pages deployment, it is often '/<projectName>/'
2121
baseUrl: '/',
@@ -77,6 +77,9 @@ const config: Config = {
7777
logo: {
7878
alt: 'RecGo Logo',
7979
src: 'img/logo.svg',
80+
href: 'https://www.uopensail.com',
81+
target: '_self'// // 设置新的跳转链接
82+
8083
},
8184
items: [
8285
{

src/pages/index.tsx

+10-10
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
import React from 'react';
2+
import { Redirect } from '@docusaurus/router'; // v2.4+ 专用
23

3-
const HtmlViewer: React.FC = () => {
4-
return (
5-
<iframe
6-
src="/cindex.html"
7-
style={{ width: '100%', height: '100vh', border: 'none' }}
8-
title="Static HTML Content" // 必须的 accessibility 属性
9-
/>
4+
export default function CustomRedirect() {
5+
// 示例:根据条件重定向
6+
const shouldRedirect = true; // 你的逻辑
7+
8+
return shouldRedirect ? (
9+
<Redirect to="https://www.uopensail.com" />
10+
) : (
11+
<div></div>
1012
);
11-
};
12-
13-
export default HtmlViewer;
13+
}

0 commit comments

Comments
 (0)