This website requires JavaScript.
Explore
Help
Sign In
vitalif
/
prettier
Watch
1
Star
0
Fork
You've already forked prettier
0
Code
Issues
Pull Requests
Releases
Wiki
Activity
e591b00005
prettier
/
tests
/
directives
/
last-line-1.js
2 lines
14 B
JavaScript
Raw
Normal View
History
Unescape
Escape
Remove last trailing line for directives-only files (#609) * Remove last trailing line for directives-only files There are two hardlines that are added that do not need to. - The first one is when there's an empty line afterwards, we want to remove it. The solution I opted for to fix this one is to trimRight the originalText so that globally it's never going to return yes for the isNextLineEmpty. - The second one is at the end of Program, but we already printed it inside of the directive itself, so we can just add a condition to make sure it's only printed when there's a body or a comment, but not a directive. Fixes #527 * Add comment
2017-02-07 18:39:04 +03:00
'use strict'
;