【问题标题】:API Documentation tool for Rails 5 [closed]Rails 5 的 API 文档工具 [关闭]
【发布时间】:2026-02-09 07:05:01
【问题描述】:

我有一个仅 API 的 rails 应用程序,它需要前端开发人员的文档。这是我第一次体验它。

您为此使用什么工具?请注意,我使用的是 rails 5 API 而不是 Grape。

我测试了Apipieswagger-blocksswagger-docs gems,但它们已经过时或有问题。一定有更好的选择!
尊重任何建议

【问题讨论】:

    标签: ruby-on-rails ruby-on-rails-5 swagger rails-api api-doc


    【解决方案1】:

    嗯,我发现 Slate 是最好的之一。

    【讨论】:

      【解决方案2】:

      您尝试过 RSpec Api 文档吗? https://github.com/zipmark/rspec_api_documentation

      这里有一篇关于将其与 codeship 结合使用的文章:https://blog.codeship.com/producing-documentation-for-your-rails-api/

      【讨论】:

      • 感谢您的回复。我以前从未使用过 rspec,但使用简单的 rails 测试单元编写了测试。你还是喜欢我吗?我能跑得快吗?