tools icon indicating copy to clipboard operation
tools copied to clipboard

`lint/style/noUnusedTemplateLiteral` does not respect `quoteStyle` of `rome.json`

Open scarf005 opened this issue 2 years ago • 1 comments

Environment information

CLI:
  Version:              11.0.0
  Color support:        true

Platform:
  CPU Architecture:     x86_64
  OS:                   linux

Environment:
  ROME_LOG_DIR:         unset
  NO_COLOR:             unset
  TERM:                 "xterm-256color"

Rome Configuration:
  Status:               loaded
  Formatter disabled:   false
  Linter disabled:      false

Workspace:
  Open Documents:       0

Discovering running Rome servers...

Incompatible Rome Server: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

i Rage discovered this running server using an incompatible version of Rome.

Server:
  Version:              11.0.0-nightly.fab5440

What happened?

playground link

image

  1. trigger lint/style/noUnusedTemplateLiteral error.

image 2. apply fixes.

image 3. rome.json settings are ignored.

// rome.json
{
  "linter": {
    "enabled": true,
    "rules": {
      "recommended": true
    }
  },
  "formatter": {
    "indentStyle": "space"
  },
  "javascript": {
    "formatter": {
      "quoteStyle": "single",
      "semicolons": "asNeeded"
    }
  }
}

Expected result

it respects quoteStyle of rome.json and replaces ` with ' when javascript.formatter.quoteStyle: "single"

Code of Conduct

  • [X] I agree to follow Rome's Code of Conduct

scarf005 avatar Jan 14 '23 11:01 scarf005

👋 @rome/staff please triage this issue by adding one of the following labels: S-Bug: confirmed, S-Planned , S-Wishlist or umbrella

github-actions[bot] avatar Jan 30 '23 12:01 github-actions[bot]