docuapi

Beautiful multilingual API documentation theme for Hugo

  • 所有者: bep/docuapi
  • 平台:
  • 许可证: Other
  • 分类:
  • 主题:
  • 喜欢:
    0
      比较:

Github星跟踪图

Netlify Status

DocuAPI is a beautiful multilingual API documentation theme for Hugo. This theme is built on top of the beautiful work of Robert Lord and others on the Slate project (Apache 2 License).

Visit the demo site.

Screenshot DocuAPI Example site

Use

The client library used to build the ToC does not handle Unicode very well. To get around this in Hugo >= 0.62.2, put this in your site config:

[markup]
  [markup.goldmark]
    [markup.goldmark.parser]
      autoHeadingIDType = "github-ascii"

Note: this theme requires Hugo >= 0.56.0 to run. If you want to edit the SCSS styles, you need:

  • The extended Hugo version.
  • PostCSS CLI (run npm install to install requirements)

See the exampleSite and more specific its site configuration for the available options.

Most notable: This theme will use all the (non drafts) pages in the site and build a single-page API documentation. Using weight in the page front matter is the easiest way to control page order.

If you want a different page selection, please provide your own layouts/index.html template.

You can customize the look-and-feel by adding your own CSS variables in assets/scss/docuapi_overrides.scss. See the exampleSite folder for an example.

Hooks

You can override the layouts by providing some custom partials:

  • partials/hook_head_end.html is inserted right before the head end tag. Useful for additional styles etc.
  • partials/hook_body_end.html which should be clear by its name.
  • partials/hook_left_sidebar_start.html the start of the left sidebar
  • partials/hook_left_sidebar_end.html the end of the left sidebar
  • partials/hook_left_sidebar_logo.html the log img source

The styles and Javascript import are also put in each partial and as such can be overridden if really needed:

  • partials/styles.html
  • partials/js.html

主要指标

概览
名称与所有者bep/docuapi
主编程语言HTML
编程语言HTML (语言数: 3)
平台
许可证Other
所有者活动
创建于2016-10-17 19:02:31
推送于2025-04-17 08:39:56
最后一次提交2025-04-17 10:39:37
发布数25
最新版本名称v2.4.2 (发布于 )
第一版名称v1.0 (发布于 2017-04-29 10:29:11)
用户参与
星数774
关注者数15
派生数202
提交数171
已启用问题?
问题数54
打开的问题数16
拉请求数37
打开的拉请求数3
关闭的拉请求数8
项目设置
已启用Wiki?
已存档?
是复刻?
已锁定?
是镜像?
是私有?