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

Fix README table example #328

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

Conversation

frejonb
Copy link

@frejonb frejonb commented Jul 6, 2024

I typically don't create PRs for trivial changes, but in this case I was learning lipgloss and it took me a bit to find the correct row styles from the table example in the README.

@bashbunni
Copy link
Member

Hey @frejonb thank you so much for your contribution! I also found table styling a bit confusing at first. I do think it makes sense to highlight this more explicitly for new users. I do have some feedback on this PR :)

If we're going to add information about styling lists it should look similar to the list section. Add a blurb mentioning custom styles, followed by a working example + capture of the output.

Tables can have custom border styles set by Lipgloss.Style using the BorderStyle function. Additionally, table content can be stylized using StyleFunc which supports conditional formatting.

// an example using BorderStyle and StyleFunc

<an image generated with freeze -x "go run ./my-example" -r 10 --window --font.size 36 --margin 20>

@bashbunni bashbunni added the documentation Improvements or additions to documentation label Aug 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants