Commit Graph

4 Commits (3654108ebe028fbc3063ceccb3c4ce0d4164510a)

Author SHA1 Message Date
Eric Sakmar 93e8b15311 verify the precedingNode type when handling import declaration comments (#5016) 2018-08-27 20:02:40 -06:00
Christopher Chedeau 069df25475 Fix last comment of import (#1677)
We used to use isBlock as a heuristic but the real thing we want is to know if the comment is on its own line. Now it works with both :)
2017-05-23 12:33:46 -07:00
Davy Duperron 748dcbf70d Fix import declaration comments (#1030)
* Add handleImportDeclarationComments function.

* Fix indent.

* Update test cases accordingly.

* Implement better heuristic for adding comments.

* Make the test case more exhaustive.
2017-03-17 08:11:43 -07:00
Christopher Chedeau 516f5900d8 Stabilize import as comments (#855)
Since this is extremely rare, I just took the easy way out and if you are adding a comment inside the "as" node, I just move it outside. We could be more fancy but that works.

Fixes #620
2017-03-02 22:22:33 -05:00