Commit Graph

5 Commits (0b07e1083339e28a8239df3f5245f530cc4fd7f8)

Author SHA1 Message Date
Jaiden Gerig 0799280429 Fixed unstable comment between function declaration and block statement (#5250) 2018-11-01 21:55:33 +02:00
Lucas Azzola 23f7e92162 Handle comments between function name and open paren (#2979) 2017-10-06 20:07:58 +11:00
Christopher Chedeau c63e21b52b Do not put parens for single argument with end of line comment (#1518)
Fixes #1517
2017-05-05 21:44:42 -07:00
Christopher Chedeau 042e603a6e Fix arrow function parenthesis with comments in flow (#1339)
`leadingComment` and `trailingComment` are babylon-specific, we should use `comments` which is what prettier adds.

Fixes #1335
2017-04-19 10:43:31 -07:00
Davy Duperron b32ace8934 Fix function declaration params comments (#802)
* Add new handleFunctionDeclarationComments function.

* Add dangling comments printing for function params.

* Add new test case.

* Update tests.

* Refactor handleFunctionDeclarationComments to only addDanglingComment when no params.

* Remove unecessary helper function, only attach dangling comments when no params.

* Reset flow tests, no more regression.
2017-02-24 07:26:30 -08:00