问题描述:

My IDE is visual studio 2015 with Resharper 9.2, I want the javascript object array initializer automatically formated like this

var x = [{

a: 1,

b: 2

},{

a: 3,

b: 4

}];

I want the round and square brackets together, Any ideas how can i do this?

It is always formatted like this:

var x = [

{

a: 1,

b: 2

},{

a: 3,

b: 4

}

];

网友答案:

You can change the formatting rules of VS as explained here. The problem should be solved by selecting either block or smart.

相关阅读:
Top