1 Star 4 Fork 3

公子骏 / forest-website

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
docusaurus.config.js 8.12 KB
一键复制 编辑 原始数据 按行查看 历史
公子骏 提交于 2022-06-30 10:44 . update: 去掉soul的链接
module.exports = {
title: 'Forest',
tagline: '更轻量、更简单实用的HTTP客户端框架',
url: 'https://www.dtflyx.com/',
baseUrl: '/',
onBrokenLinks: 'throw',
favicon: 'img/favicon.ico',
organizationName: 'dt_flys', // Usually your GitHub org/user name.
projectName: 'forest', // Usually your repo name.
customFields: {
subtitle: "Forest能够帮助您使用更简单的方式编写Java的HTTP客户端,快速接入第三方RESTful接口",
lastVersion: '1.5.24',
lastVersionUrl: 'https://gitee.com/dromara/forest/releases/v1.5.24',
},
scripts: [
'/scripts/baidu.js',
'https://cdn.wwads.cn/js/makemoney.js',
'/scripts/whitelist.js'
],
themeConfig: {
colorMode: {
defaultMode: "dark",
disableSwitch: true,
respectPrefersColorScheme: false,
switchConfig: {
darkIcon: "🌙",
darkIconStyle: {
marginLeft: "2px",
},
lightIcon: "☀️",
lightIconStyle: {
marginLeft: "1px",
},
},
},
prism: {
additionalLanguages: ['java', 'yaml', 'properties', 'groovy'],
theme: require('prism-react-renderer/themes/dracula'),
},
algolia: {
apiKey: 'dd15d1ad8483935e1cb9d8cc0e6cbf6c',
indexName: 'dtflyx',
contextualSearch: true,
appId: 'BH4D9OD16A',
// Optional: Algolia search parameters
searchParameters: {
// facetFilters: ["type:lvl15"]
},
//... other Algolia params
debug: false
},
navbar: {
title: '',
logo: {
alt: 'Forest',
src: 'img/logo-banner.svg',
},
items: [
{
type: 'docsVersionDropdown',
position: 'left',
},
{
label: '文档',
position: 'left',
to: 'docs/',
},
{
label: '历史版本',
position: 'left',
to: 'https://gitee.com/dromara/forest/releases'
},
{
label: '关于作者',
position: 'left',
to: 'blog/2020/11/13/about-me'
},
// {to: 'blog', label: 'Blog', position: 'left'},
{
label: '社区',
// className: 'navbar-community-board',
href: 'https://dromara.org/zh',
position: 'right',
},
{
href: 'https://gitee.com/dromara/forest',
// className: 'navbar-item-gitee',
label: 'Gitee',
position: 'right',
},
{
href: 'https://github.com/dromara/forest',
// className: 'navbar-item-github',
label: 'GitHub',
position: 'right',
},
{
label: '赞助',
position: 'left',
to: 'docs/donate',
position: 'right',
},
],
},
footer: {
style: 'dark',
links: [
{
title: '文档',
items: [
{
label: '入门',
href: 'https://forest.dtflyx.com/docs/',
},
{
label: '基础',
href: 'https://forest.dtflyx.com/docs/basic/build_interface',
},
{
label: 'JavaDoc',
href: 'https://apidoc.gitee.com/dromara/forest/',
},
]
},
{
title: '社区',
items: [
{
label: '讨论',
href: 'https://gitee.com/dromara/forest/issues',
},
{
label: '微信群',
href: 'https://forest.dtflyx.com/docs/author',
},
{
label: 'Dromara',
href: 'https://gitee.com/dromara',
},
]
},
{
title: '更多',
items: [
{
label: 'Gitee',
href: 'https://gitee.com/dromara/forest',
},
{
label: 'Github',
href: 'https://github.com/dromara/forest',
},
]
},
],
logo: {
alt: 'Dromara Open Source Logo',
src: 'img/dromara-logo.png',
href: 'https://gitee.com/dromara',
},
copyright: `<a href="https://beian.miit.gov.cn/">沪ICP备18012980号-2</a><br>The MIT License (MIT) | Copyright © ${new Date().getFullYear()} Jun Gong`,
},
},
presets: [
[
/*
'@docusaurus/plugin-content-docs',
{
path: 'docs',
// Simple use-case: string editUrl
// editUrl: 'https://github.com/facebook/docusaurus/edit/main/website/',
// Advanced use-case: functional editUrl
editUrl: ({versionDocsDirPath, docPath}) =>
`https://gitee.com/dt_flys/forest-website/tree/master/versioned_docs/${versionDocsDirPath}/${docPath}`,
editLocalizedFiles: false,
editCurrentVersion: false,
routeBasePath: 'docs',
include: ['**!/!*.md', '**!/!*.mdx'],
exclude: [
'**!/_*.{js,jsx,ts,tsx,md,mdx}',
'**!/_*!/!**',
'**!/!*.test.{js,jsx,ts,tsx}',
'**!/__tests__/!**',
],
sidebarPath: 'sidebars.js',
sidebarItemsGenerator: async function ({
defaultSidebarItemsGenerator,
numberPrefixParser,
item,
version,
docs,
}) {
// Use the provided data to generate a custom sidebar slice
return [
{type: 'doc', id: 'intro'},
{
type: 'category',
label: 'Tutorials',
items: [
{type: 'doc', id: 'tutorial1'},
{type: 'doc', id: 'tutorial2'},
],
},
];
},
numberPrefixParser: function (filename) {
// Implement your own logic to extract a potential number prefix
const numberPrefix = findNumberPrefix(filename);
// Prefix found: return it with the cleaned filename
if (numberPrefix) {
return {
numberPrefix,
filename: filename.replace(prefix, ''),
};
}
// No number prefix found
return {numberPrefix: undefined, filename};
},
docLayoutComponent: '@theme/DocPage',
docItemComponent: '@theme/DocItem',
remarkPlugins: [require('remark-math')],
rehypePlugins: [],
beforeDefaultRemarkPlugins: [],
beforeDefaultRehypePlugins: [],
showLastUpdateAuthor: false,
showLastUpdateTime: false,
disableVersioning: false,
includeCurrentVersion: true,
lastVersion: undefined,
versions: {
current: {
label: 'Android SDK v2.0.0 (WIP)',
path: 'android-2.0.0',
banner: 'none',
},
'1.0.0': {
label: 'Android SDK v1.0.0',
path: 'android-1.0.0',
banner: 'unmaintained',
},
},
onlyIncludeVersions: ['current', '1.0.0', '2.0.0'],
},
*/
'@docusaurus/preset-classic',
{
docs: {
lastVersion: 'current',
versions: {
current: {
label: '1.5.x',
path: '/',
},
},
showLastUpdateAuthor: false,
showLastUpdateTime: true,
sidebarPath: require.resolve('./sidebars.json'),
// Please change this to your repo.
editUrl:
'https://gitee.com/dt_flys/forest-website/tree/master/',
},
blog: {
showReadingTime: true,
// Please change this to your repo.
editUrl:
'https://gitee.com/dt_flys/forest-website/tree/master/',
},
sitemap: {
// cacheTime: 600 * 1000, // 600 sec - cache purge period
changefreq: "daily",
priority: 0.7,
trailingSlash: true,
},
theme: {
customCss: require.resolve('./src/css/custom.css'),
},
},
],
],
};
JavaScript
1
https://gitee.com/dt_flys/forest-website.git
git@gitee.com:dt_flys/forest-website.git
dt_flys
forest-website
forest-website
master

搜索帮助