Add a blank_line() method to Builder #13

Merged
cadey merged 1 commits from :blank-line into main 2020-12-06 01:14:25 +00:00
First-time contributor

Many times users may want to seperate lines of text using a blank line. Currently, this can be accomplished by either adding '\n' to the previous text() call, which requires that the user has the ability to access this, and can also look a little messy, or by calling text() with an empty string, which definately works, but having an explicit method might be a nice sugar for a lot of users, and barely adds any weight to the codebase.

This is definately a small thing, and almost closer to a personal preferance than anything, but I definately think it would make the library a tiny bit nicer to use, and there's barely any tradeoff. It's still up to you though if you'd rather keep your codebase small.

I've also written a simple doctest for this method in commit adf82e9, but this isn't included in this PR, since it's contingent on the merge of #12.

Many times users may want to seperate lines of text using a blank line. Currently, this can be accomplished by either adding '\n' to the previous `text()` call, which requires that the user has the ability to access this, and can also look a little messy, or by calling `text()` with an empty string, which definately works, but having an explicit method might be a nice sugar for a lot of users, and barely adds any weight to the codebase. This is definately a small thing, and almost closer to a personal preferance than anything, but I definately think it would make the library a tiny bit nicer to use, and there's barely any tradeoff. It's still up to you though if you'd rather keep your codebase small. I've also written a simple doctest for this method in commit adf82e9, but this isn't included in this PR, since it's contingent on the merge of #12.
cadey merged commit cf73a3bb1e into main 2020-12-06 01:14:25 +00:00
Ghost deleted branch blank-line 2020-12-06 14:27:42 +00:00
Sign in to join this conversation.
No description provided.