-
Notifications
You must be signed in to change notification settings - Fork 61
failing to remove whitespace from markdown file #68
Comments
I'm having the same issue. I select some text in MD file, choose "Remove trailing whitespace" from menu and nothing happens. Using Atom 1.4.1. |
There was a new configuration option ( |
I understand that you're talking about settings for automatic removing of whitespace when I save the file. This isn't the case here: I'm explicitly asking Atom to remove trailing whitespace by selecting the relevant menu option. Whatever the config, this option should definitely do what it says. |
Yeah, that would make sense (especially if you're running it on a selection), but this block of code is what's getting run, whether it's triggered manually or on save. |
Okay, good, so you know where is the bug coming from 😊 Shall we reopen it (@lee-dohm) or should I create a new issue? |
@mik01aj Please open a new issue. |
I ran into a markdown file that had a bunch of trailing whitespace. None of it was actually required for it to render properly, it was just there by mistake. So I opened & saved the file with Atom, expecting it to be stripped, but only some of it was (all the lines with 2 trailing spaces remained). Using the "Whitespace: Remove Trailing Whitespace" command also failed to strip it.
I think that this is the code responsible - some special logic for leaving 2 spaces alone in GFM.
I propose that we either remove this, since nearly the same thing can be accomplished if people who use trailing whitespace in their markdown added the following to their config:
...or at least make enabling it an option, since I only found out about it by reading the source.
The text was updated successfully, but these errors were encountered: