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

indent: ignoring nested arrays/objects causes subsequent fields to be ignored #11445

Closed
tony19 opened this issue Feb 26, 2019 · 2 comments
Closed
Labels
archived due to age This issue has been archived; please open a new issue for any further discussion auto closed The bot closed this issue triage An ESLint team member will look at this issue soon

Comments

@tony19
Copy link

tony19 commented Feb 26, 2019

Tell us about your environment

  • ESLint Version: 5.14.1
  • Node Version: 10.11.0
  • npm Version: 6.4.1

What parser (default, Babel-ESLint, etc.) are you using?
Occurs with either default or Babel-ESLint

Please show your full configuration:

Configuration
// .eslintrc.js
module.exports = {
  rules: {
    "indent": [
      "error",
      4,
      {
        "ignoredNodes": [
          '[value.type="ObjectExpression"]',
          '[value.type="ArrayExpression"]'
        ]
      }
    ]
  }
}

What did you do? Please include the actual source code causing the issue, as well as the command that you used to run ESLint.

function foo() {
return {
a: 1,
b: [],
c: 1,
d: {},
e: 2
}
}
./node_modules/.bin/eslint --config .eslintrc.js --fix src/foo.js

What did you expect to happen?

function foo() {
    return {
        a: 1,
b: [],
        c: 1,
d: {},
        e: 2
    }
}

What actually happened? Please include the actual, raw output from ESLint.

function foo() {
    return {
        a: 1,
b: [],
c: 1,   
d: {},
e: 2    
    }
}
@tony19
Copy link
Author

tony19 commented Feb 26, 2019

@tony19 tony19 changed the title indent: ignore-selector causes all fields after nested array/object to be ignored indent: ignoring nested arrays/objects causes all fields afterward to be ignored Feb 26, 2019
@tony19 tony19 changed the title indent: ignoring nested arrays/objects causes all fields afterward to be ignored indent: ignoring nested arrays/objects causes subsequent fields to be ignored Feb 26, 2019
@eslint-deprecated eslint-deprecated bot added the auto closed The bot closed this issue label Mar 30, 2019
@eslint-deprecated
Copy link

Unfortunately, it looks like there wasn't enough interest from the team
or community to implement this change. While we wish we'd be able to
accommodate everyone's requests, we do need to prioritize. We've found
that issues failing to reach accepted status after 21 days tend to
never be accepted, and as such, we close those issues.
This doesn't mean the idea isn't interesting or useful, just that it's
not something the team can commit to.

Thanks for contributing to ESLint and we appreciate your understanding.

@eslint-deprecated eslint-deprecated bot locked and limited conversation to collaborators Sep 27, 2019
@eslint-deprecated eslint-deprecated bot added the archived due to age This issue has been archived; please open a new issue for any further discussion label Sep 27, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
archived due to age This issue has been archived; please open a new issue for any further discussion auto closed The bot closed this issue triage An ESLint team member will look at this issue soon
Projects
None yet
Development

No branches or pull requests

1 participant