Plugin currently Formats Code with a Block Lambda Argument like this:
[].filter(b=>true)
.forEach(() => {
console.log("test");
});
As you can see, the function body is on the same level as the method chaining, so the code isn't readable at all.
I believe this to be the correct indentation:
[].filter(b=>true)
.forEach(() => {
console.log("test");
});
📓 Side note: also when adding a comment above any chained method, it always starts without indentation, even if it's indented all around it.
[].filter(b=>true)
// Comment above a chained method should be indented
.forEach(() => {
console.log("test");
});
Method chaining per line is very popular for good code readability, so I hope it's within the scope of this plugin's formatter 🙂
Plugin currently Formats Code with a Block Lambda Argument like this:
As you can see, the function body is on the same level as the method chaining, so the code isn't readable at all.
I believe this to be the correct indentation:
📓 Side note: also when adding a comment above any chained method, it always starts without indentation, even if it's indented all around it.
Method chaining per line is very popular for good code readability, so I hope it's within the scope of this plugin's formatter 🙂