1 Star 0 Fork 7

Mark_Li/hust_mirrors

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
docusaurus.config.js 2.78 KB
一键复制 编辑 原始数据 按行查看 历史
程子丘 提交于 2023-09-09 17:33 . feat: add cliAd ast plugin.
// @ts-check
// Note: type annotations allow type checking and IDEs autocompletion
const lightCodeTheme = require('prism-react-renderer/themes/github');
const darkCodeTheme = require('prism-react-renderer/themes/dracula');
const mirrorConfig = require('./mirrors.config');
/** @type {import('@docusaurus/types').Config} */
const config = {
title: mirrorConfig.title,
favicon: 'img/favicon.png',
// Set the production url of your site here
url: mirrorConfig.url,
// Set the /<baseUrl>/ pathname under which your site is served
// For GitHub pages deployment, it is often '/<projectName>/'
baseUrl: '/',
onBrokenLinks: 'throw',
onBrokenMarkdownLinks: 'warn',
i18n: {
defaultLocale: 'zh-Hans',
locales: ['zh-Hans', 'en'],
},
presets: [
[
'classic',
/** @type {import('@docusaurus/preset-classic').Options} */
({
docs: {
sidebarPath: require.resolve('./sidebars.js'),
remarkPlugins: [require('./plugin/remark/varcode'), require('./plugin/remark/cliAd')],
// Please change this to your repo.
// Remove this to remove the "edit this page" links.
editUrl:
'https://gitee.com/dzm91_hust/hust-mirrors/blob/master/'
},
blog: {
showReadingTime: true,
// Please change this to your repo.
// Remove this to remove the "edit this page" links.
editUrl:
'https://gitee.com/dzm91_hust/hust-mirrors/blob/master/',
},
theme: {
customCss: require.resolve('./src/css/custom.css'),
},
}),
],
],
themeConfig:
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
({
// Replace with your project's social card
image: 'img/docusaurus-social-card.jpg',
navbar: {
title: mirrorConfig.mainTitle,
logo: {
alt: mirrorConfig.mainTitle,
src: 'img/logo.svg',
},
items: [
{
type: 'docSidebar',
sidebarId: 'tutorialSidebar',
position: 'left',
label: '帮助',
},
{
to: '/blog',
label: '动态',
position: 'left'
},
{
type: 'localeDropdown',
position: 'right',
},
{
href: 'https://gitee.com/dzm91_hust/hust-mirrors/blob/master/',
label: 'Gitee',
position: 'right',
},
],
},
footer: {
style: 'light',
copyright: `华中科技大学开源镜像站由 华中科技大学网络中心 提供支持。`
},
prism: {
theme: lightCodeTheme,
darkTheme: darkCodeTheme,
},
}),
plugins: [
require('./plugin/fancyindex')
]
};
module.exports = config;
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/lilanzhe2024/hust-mirrors.git
git@gitee.com:lilanzhe2024/hust-mirrors.git
lilanzhe2024
hust-mirrors
hust_mirrors
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385