rails / sdoc

Standalone sdoc generator
http://api.rubyonrails.org/
Other
819 stars 132 forks source link

Move config from Rails to SDoc #333

Open p8 opened 1 year ago

p8 commented 1 year ago

Currently generating the API docs is integrated in the Rails project: https://github.com/rails/rails/blob/main/railties/lib/rails/api/task.rb This requires the sdoc gem to work with the supported Ruby version of the Rails project and its Gemfile. If docs generation can be run seperately we can generate the docs for any version of Rails.

zzak commented 1 year ago

Yeah, this is a known issue but I'm not sure where to put it yet.

p8 commented 1 year ago

I think we could have some config file in sdoc where we define the settings for each version of Rails.

p8 commented 10 months ago

RDoc supports a .rdoc_options file We could move a lot of options there.

zzak commented 3 weeks ago

Ok, the last issue. I left this because I think it's actually nice backend work we can do without disrupting any UX stuff.

The goal is to have SDoc be able to generate the Rails API docs for any version. So not relying on configuration based in-repo.

This way we can have a single process to build the docs for all (stable) versions of Rails when we deploy, and changes or improvements to the UI will be applied everywhere. That removes the jarring effect of viewing older version of the docs and getting lost (not that I don't love the nostalgia of the old ui).