While using Rider recently, I found that the code that I had written had unnecessary whitespace. Here’s how I got Rider to notify me when there’s unnecessary whitespace:
- Go to settings (In Windows/Linux: File => Settings; Mac: Jetbrains Rider Menu => Settings).
- In the left pane, click on the arrow next to
Editor. Then click on
- In the right pane, Expand
Syntax Style. Click to enable “Unnecessary whitespace at the end of the line”.
- To the right of “Unnecessary whitespace at the end of the line” choose the notification level: Hint, Suggestion, Warning, or Error.
- Once you have chosen that, click on Save. If you click on the arrow next to Save, you can choose to save the settings to the solution you have open or to your computer.