Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I get VisualStudio 2010 with ReSharper to preserve my spaces between '<%:', content, and '%>'?

I have Visual Studio 2010 and ReSharper installed and after looking for about an hour, I can't find this formatting setting anywhere.

I'd like it to look like this:

<div><%: Model.Something %></div>

and it keeps removing my space between Model.Something and %> to look like this:

<div><%: Model.Something%></div>
like image 649
Joe Avatar asked Dec 08 '11 23:12

Joe


1 Answers

This behavior would be fixed in the next EAP of ReSharper 6.1, maybe even in beta. Sorry, had no time for an option - for 6.1 there would be spaces always, hopefully most of ASP.NET developers would like it that way.

P.S. In older versions you can switch it via option ReSharper | Options | Languages | C# | Formatting Style | Spaces -> Within parentheses -> Method call parentheses. But switching it also affects C# method calls.

like image 195
Dmitry Osinovskiy Avatar answered Nov 14 '22 14:11

Dmitry Osinovskiy