Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DOC] Correction for doc guide + TOC fix in File #8505

Merged
merged 2 commits into from Sep 24, 2023
Merged

[DOC] Correction for doc guide + TOC fix in File #8505

merged 2 commits into from Sep 24, 2023

Conversation

BurdetteLamar
Copy link
Member

The doc guide is corrected to omit reference to GFM tables, which RDoc does not support.

In linking to verbatim example, I discovered an TOC jump-level that caused most of the headings in File doc to be omitted from the doc's left-TOC for the class. Now corrected.

@BurdetteLamar BurdetteLamar added the Documentation Improvements to documentation. label Sep 23, 2023
Comment on lines -221 to -223
- The GFM (GitHub Flavored Markdown) table extension,
which is enabled by default. See
{GFM tables extension}[https://github.github.com/gfm/#tables-extension-].
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

RDoc doe support GFM tables, but only in markdown files. For example, doc/contributing/glossary.md is generated at: https://docs.ruby-lang.org/en/master/contributing/glossary_md.html

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. Can the doc for a single class/module/method/etc. be markdown? Or must the entire file be markdown? (Asking for a friend.)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to the readme:

You can also set the comment format for a single file through the :markup: directive, but this is only recommended if you wish to switch markup formats.

So I think you can switch to markdown by using :markup: markdown.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Modified.

using special formatting for the text:

- Example {source}[https://github.com/ruby/ruby/blob/34d802f32f00df1ac0220b62f72605827c16bad8/doc/contributing/glossary.md?plain=1].
- Corresponding {output}[https://docs.ruby-lang.org/en/master/contributing/glossary_md.html].
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These examples are well-chosen, and the links to the plain-text source variant is also thoughtful. 👍

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Credit to @peterzhu2118 for the GFM example.

Copy link
Contributor

@olleolleolle olleolleolle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @BurdetteLamar!

@peterzhu2118 peterzhu2118 merged commit 36cd2b2 into ruby:master Sep 24, 2023
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Documentation Improvements to documentation.
3 participants