Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closing-brace indentation is not checked for object literals #959

Open
js-choi opened this issue Jul 27, 2017 · 1 comment

Comments

@js-choi
Copy link

commented Jul 27, 2017

All this was tested using version 10.0.2 and can be demonstrated on the demo web page.

This code with an if block is Standard Style:

const x = true

if (x) {
  console.log(x)
}

This code is not Standard Style; it violates brace-style:

const x = true

if (x) {
  console.log(x) }

This code with an object literal is Standard Style:

const x = {
  a: 3
}

console.log(x)

This presumably isn’t Standard Style; it probably ought to violate brace-style:

const x = {
  a: 3 }

console.log(x)

But Standard considers the final code block to also be valid Standard Style.

@stale

This comment has been minimized.

Copy link

commented May 10, 2018

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added the stale label May 10, 2018

@stale stale bot closed this May 17, 2018

@feross feross added the bug label May 20, 2018

@feross feross reopened this May 20, 2018

@stale stale bot removed the stale label May 20, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
2 participants
You can’t perform that action at this time.