Formatting of arrow-function inconsistent with StandardJS
nknapp opened this issue · comments
Nils Knappmeier commented
The following snippet is an example that is correctly formatted (according to standard
):
window.abc = (param) => JSON.stringify({
param: param
})
standard --format
changes the indentation of the last two lines and standard
returns an error for the result:
window.abc = (param) => JSON.stringify({
param: param
})
Errors:
standard: Use JavaScript Standard Style (https://github.com/feross/standard)
.../test.js:2:5: Expected indentation of 2 space characters but found 4.
.../test.js:3:3: Expected indentation of 0 space characters but found 2.
Feross Aboukhadijeh commented
You should use standard --fix
instead of this package. standard-format
isn't being actively maintained anymore.