Open Bug 1774360 Opened 2 years ago Updated 2 years ago

Editor pretty print result is incorrect with Records

Categories

(DevTools :: Console, defect, P3)

defect

Tracking

(Not tracked)

People

(Reporter: nchevobbe, Unassigned)

References

(Blocks 1 open bug)

Details

Steps to reproduce

  1. Open the console, switch to editor mode
  2. Paste the following in the input
#{
  hello: "world"
}
  1. Click the pretty print ({}) button in the editor toolbox

Actual results

The expression is transformed into

# {
  hello: "world"
}

Notice the space between # and {: evaluating this would lead to a SyntaxError


This will require jsbeautify to be updated (see https://searchfox.org/mozilla-central/source/devtools/shared/jsbeautify/UPGRADING.md)
We should check if there's an issue on the jsbeautify and if not, file it

Severity: -- → S3
Priority: -- → P3
You need to log in before you can comment on or make changes to this bug.