8000 Bad indent when use switch case · Issue #1979 · standard/standard · GitHub
[go: up one dir, main page]

Skip to content

Bad indent when use switch case #1979

@ssheduardo

Description

@ssheduardo

I have vscode clear, only with eslint, prettier (disabled global in vscode to test).
The problem is when create a simple file JS with switch, if save or apply eslint fix in the terminal, the indent level beetween switch and case, same level, that no indent correctly if I try indent manually, the standard mark error.

Image

Image

This is my .eslintrc.json

{
  "extends": ["standard"],
  "rules": {
    "semi": ["error", "never"], // No usar punto y coma
    "quotes": ["error", "single"], // Usar comillas simples
    "space-before-function-paren": ["error", "always"],
    "indent": ["error", 2]
  }
}

Part of my package.json

  "devDependencies": {
    "eslint": "^8.57.1",
    "eslint-config-standard": "^17.1.0",
    "standard": "^17.1.2"
  },
  "eslintConfig": {
    "extends": "standard"
  },

This is my settings.json

{
  "editor.codeActionsOnSave": {
    "source.fixAll.eslint": "explicit"
  },

  "editor.formatOnSave": false,

  "[javascript]": {
    "editor.defaultFormatter": "dbaeumer.vscode-eslint"
  },

  "[json]": {
    "editor.defaultFormatter": "esbenp.prettier-vscode"
  },
  "[markdown]": {
    "editor.defaultFormatter": "esbenp.prettier-vscode"
  },
 
  "[php]": {
    "editor.defaultFormatter": "bmewburn.vscode-intelephense-client"
  },

  "[blade]": {
    "editor.defaultFormatter": "onecentlin.laravel-blade"
  },
  "files.eol": "\n",
  "tailwindCSS.emmetCompletions": true,
  "eslint.alwaysShowStatus": true,
  "editor.largeFileOptimizations": true,
  "workbench.iconTheme": "material-icon-theme",
  "files.autoSave": "onFocusChange",
  "editor.tabSize": 2
}

Where is wrong, I deleted all my plugin and configurations of Vscode and starting again.

Sorry by my English.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0