question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Feature Request] Add commas at end of arguments

See original GitHub issue

This would be great to preserve blame in commits.

Input

Test(
1,
2
)

Current output

Test(
1,
2
)

Expected output

Test(
1,
2,
)

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
kddnewtoncommented, Feb 12, 2019

This will be supported in the next release (0.4.0) which I’ll push out this morning. In your config you should specify trailingComma: true

0reactions
kddnewtoncommented, Feb 12, 2019

This is now out.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Should I add a trailing comma after the last argument in a ...
So yes, there are many situations where you can expect your list of functions arguments to grow and where it should be acceptable...
Read more >
Best practices for using trailing commas in JavaScript
We'll start with the common data types, like arrays and objects, where you can safely add a trailing comma to the end of...
Read more >
Trailing commas - JavaScript - MDN Web Docs
Trailing commas (sometimes called "final commas") can be useful when adding new elements, parameters, or properties to JavaScript code.
Read more >
Allow trailing commas in function calls - DevForum | Roblox
The idea behind the trailing comma is to reduce unnecessary diff lines as you work and commit on the files. Having a -1...
Read more >
Why you should enforce Dangling Commas for Multiline ...
We all have different opinions on what code should look like. Most of the time it's a matter of preference based on good...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found