Formatting
Blank lines are useful in a letter and useless in a list you are about to sort or count. This page deletes a line whose trim is empty: a truly empty line, or a line of spaces and tabs. Lines that contain anything else stay, in the same order, joined with ordinary newlines.
“Odd socks”, then a line with one space, then an empty line, then “in the dryer.” becomes two lines: Odd socks, then in the dryer. The visual gap is gone. Interior spaces on a kept line are not collapsed, and the ends of a kept line are not trimmed. “ Odd socks ” would survive with its padding, because after a trim it is still not empty.
A paragraph that never had a blank line is unchanged. “Odd socks in the dryer.” is one line in and one line out. This is not the dedupe tool: two identical non-blank lines both stay. It is not the trim tool: padding on a real line stays. A line that holds only a non-breaking space is empty for this test, because the emptiness check trims Unicode whitespace, not just the space bar.
Odd socks\n \n\nin the dryer.
Odd socks in the dryer. The line that held a single space is gone, and so is the fully empty line.
Oddsock runs this in your browser. It is free, it does not upload the work, and it does not ask for an account.
Yes. Spaces and tabs trim away to nothing, so that line is deleted. A line with a visible character, even a period, stays.
No. “ Odd socks ” remains padded. Trim is a different operation.
Both stay. Emptiness is the only test. Dedupe is the page that drops repeated text.
A blank line between Markdown paragraphs is removed, and the paragraphs become adjacent lines. That can change how a later Markdown renderer reads the file.
A line that is only non-breaking spaces is deleted. The emptiness check uses trim, and trim treats a non-breaking space, an em space, and a byte-order mark as whitespace. A zero-width space is not whitespace, so a line of those can survive.