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

fix(formatter): prevent comments from being eaten by formatter #2578

Merged
merged 3 commits into from
Apr 24, 2024

Conversation

ah-yu
Copy link
Contributor

@ah-yu ah-yu commented Apr 24, 2024

Summary

// input
console.log((first,last/* comment */));

// before 
// the formatter eats the comment
console.log((first, last));

// after
console.log((first, last) /* comment */);

Test Plan

Add a new test case and update prettier snapshots

@github-actions github-actions bot added A-Formatter Area: formatter L-JavaScript Language: JavaScript and super languages A-Changelog Area: changelog labels Apr 24, 2024
Copy link

codspeed-hq bot commented Apr 24, 2024

CodSpeed Performance Report

Merging #2578 will degrade performances by 24.63%

Comparing ah-yu:refmt_paren (604480d) with main (7ea5dff)

Summary

❌ 1 regressions
✅ 92 untouched benchmarks

⚠️ Please fix the performance issues or acknowledge them on CodSpeed.

Benchmarks breakdown

Benchmark main ah-yu:refmt_paren Change
big5-added.json[uncached] 2.7 ms 3.6 ms -24.63%

@ah-yu ah-yu merged commit 15ca346 into biomejs:main Apr 24, 2024
11 of 12 checks passed
@ah-yu ah-yu deleted the refmt_paren branch April 24, 2024 06:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Changelog Area: changelog A-Formatter Area: formatter L-JavaScript Language: JavaScript and super languages
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants