提问人:Shipswake 提问时间:11/16/2023 更新时间:11/16/2023 访问量:14
Redocusaurus 插件不支持的规范错误
Unsupported specification error with Redocusaurus plugin
问:
我正在使用 docFx 版本 2.73.2 从 ASP Net Core API 创建.yml文件。
当我尝试使用 Redocusaurus 插件创建 Docusaurus 站点时,我收到了一个 Unsupported Specification 错误。
docfx 配置文件
{
"metadata": [
{
"src": [
{
"src": "../",
"files": [
"src/**.csproj"
]
}
],
"dest": "api",
"disableGitFeatures": false,
"disableDefaultFilter": false,
"filter": "filterConfig.yml"
}
],
"build": {
"content": [
{
"files": [
"api/**.{md,yml}",
"api/index.md"
]
},
{
"files": [
"articles/**.md",
"articles/**/toc.yml",
"toc.yml",
"*.md"
]
}
],
"resource": [
{
"files": [
"images/**"
]
}
],
"overwrite": [
{
"files": [
"apidoc/**.md"
],
"exclude": [
"obj/**",
"_site/**"
]
}
],
"dest": "_site",
"globalMetadataFiles": [],
"fileMetadataFiles": [],
"template": [
"default",
"docfx-tmpl/src"
],
"postProcessors": [],
"markdownEngineName": "markdig",
"noLangKeyword": false,
"keepFileLink": false,
"cleanupCacheHistory": false,
"disableGitFeatures": false
}
}
Docusaurus 配置预设定义
presets: [
[
'classic',
{
docs: {
sidebarPath: './sidebars.ts',
},
blog: false,
theme: {
customCss: './src/css/custom.css',
},
} satisfies Preset.Options,
],
[
'redocusaurus',
{
// Plugin Options for loading OpenAPI files
specs: [
{
spec: 'path/to.yml',
route: '/api/',
},
],
// Theme Options for modifying how redoc renders them
theme: {
// Change with your site colors
primaryColor: '#1890ff',
},
},
],
],
我已经尝试了 docFx 和 Redocusaurus 上的多次配置更改,但似乎没有任何效果
任何帮助都非常感谢
答: 暂无答案
评论