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

Options to disable top and bottom frames #57

Open
halostatue opened this issue Nov 9, 2023 · 0 comments
Open

Options to disable top and bottom frames #57

halostatue opened this issue Nov 9, 2023 · 0 comments

Comments

@halostatue
Copy link

The Text renderer is really close to being able to produce a GFM table:

Table.new(rows, header)
|> Table.render!(intersection_symbol: "|", top_frame_symbol: nil, bottom_frame_symbol: nil)
|> IO.puts()

If instead we could add top_frame: false and bottom_frame: false, then we would absolutely have a GFM table.

The workaround is similar to that in #14:

rows
|> Table.new(header)
|> Table.render!(intersection_symbol: "|")
|> String.trim_trailing("\n")
|> String.split("\n")
|> List.delete_at(0)
|> List.delete_at(-1)
|> Enum.join("\n")
|> IO.puts()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant