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

🐛 Reformat issue with escaped character in stringified object key #3482

Closed
1 task done
Conaclos opened this issue Jul 21, 2024 · 0 comments · Fixed by #3558
Closed
1 task done

🐛 Reformat issue with escaped character in stringified object key #3482

Conaclos opened this issue Jul 21, 2024 · 0 comments · Fixed by #3558
Assignees
Labels
A-Formatter Area: formatter L-JavaScript Language: JavaScript and super languages S-Bug-confirmed Status: report has been confirmed as a valid bug S-Help-wanted Status: you're familiar with the code base and want to help the project

Comments

@Conaclos
Copy link
Member

Environment information

Playground and Biome 1.8.3

What happened?

The reformat issue is in the prettier::js::quote-props::object test.
Given the follwing code:

a = {
  "\a": 1,
  "b": 2
}

Formatting a first time leads to (Playground):

a = {
  "a": 1,
  "b": 2
}

AQnd the second time:

a = {
  a: 1,
  "b": 2
}

Expected result

Prettier formats the example directly into:

a = {
  a: 1,
  "b": 2
}

Biome should exhibit the same behavior.

Code of Conduct

  • I agree to follow Biome's Code of Conduct
@Conaclos Conaclos added A-Formatter Area: formatter L-JavaScript Language: JavaScript and super languages S-Bug-confirmed Status: report has been confirmed as a valid bug S-Help-wanted Status: you're familiar with the code base and want to help the project labels Jul 21, 2024
@Conaclos Conaclos self-assigned this Jul 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Formatter Area: formatter L-JavaScript Language: JavaScript and super languages S-Bug-confirmed Status: report has been confirmed as a valid bug S-Help-wanted Status: you're familiar with the code base and want to help the project
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant