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

Next up! Line wrapping! #21

Open
dgkf opened this issue Aug 18, 2022 · 0 comments
Open

Next up! Line wrapping! #21

dgkf opened this issue Aug 18, 2022 · 0 comments

Comments

@dgkf
Copy link
Collaborator

dgkf commented Aug 18, 2022

I've been pleased with the introduction of the block class. I think the next step is to introduce line wrapping.

I'm torn between two different ways of approaching this.

While walking sub-tags, we keep track of the remaining space on the current line so that newlines can be inserted without knowledge of the parent tag. In this style, each child expression will be formed properly so that they can all be joined together in the parent tag.

or

We can split elements that can be wrapped into individual wrap-able words, more like a flat-map that generates individual wrapable components.

For now, my plan is to just try out a few of these to see if one fits particularly better than the other. Interested if anyone has any thoughts to steer this, though.

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