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

improve formatting of values table #106

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

kd7lxl
Copy link
Contributor

@kd7lxl kd7lxl commented Aug 17, 2021

Deeply nested values can cause the values table to grow really wide. The key field is not wrapped by default. Example: https://github.com/cortexproject/cortex-helm-chart/blob/cc9ef3dc/README.md#values

By adding zero-width spaces after the .s in the keys, the browser will wrap long keys when needed. Here's an example, notice the table is much narrower and much more readable:
https://github.com/cortexproject/cortex-helm-chart/blob/f6454e5/README.md#values

@norwoodj
Copy link
Owner

norwoodj commented Apr 3, 2022

Hey @kd7lxl I like this change in principle and I'm sorry I hadn't looked at this until now. I have only one concern. I think quoted key components which contain dots should be left alone, e.g. controller.service.annotations."external-dns.alpha.kubernetes.io/hostname". This is a feature of helm-docs, to quote components of keys that contain dots to indicate that each component of the inner key is not nested. I don't think we should allow for splitting lines on these types of keys.

@Nepo26 Nepo26 mentioned this pull request Jul 3, 2023
12 tasks
@Nepo26 Nepo26 added this to the General Cleanup milestone Jul 25, 2023
@norwoodj norwoodj self-assigned this Nov 2, 2023
@norwoodj norwoodj added the enhancement New feature or request label Nov 2, 2023
@Silthus
Copy link

Silthus commented Apr 11, 2024

Could you also, maybe in this PR, fix the formatting of the table when long defaults are used?
Currently the description is completely hidden from the viewport.
Another option would be to add an option to order the table columns to make the description show first.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants