(path, options, print)
| 43 | } |
| 44 | |
| 45 | function printChild(path, options, print) { |
| 46 | const child = path.node; |
| 47 | |
| 48 | if (hasPrettierIgnore(child)) { |
| 49 | const endLocation = getEndLocation(child); |
| 50 | |
| 51 | return [ |
| 52 | printOpeningTagPrefix(child, options), |
| 53 | replaceEndOfLine( |
| 54 | htmlWhitespace.trimEnd( |
| 55 | options.originalText.slice( |
| 56 | locStart(child) + |
| 57 | (child.prev && needsToBorrowNextOpeningTagStartMarker(child.prev) |
| 58 | ? printOpeningTagStartMarker(child).length |
| 59 | : 0), |
| 60 | endLocation - |
| 61 | (child.next && needsToBorrowPrevClosingTagEndMarker(child.next) |
| 62 | ? printClosingTagEndMarker(child, options).length |
| 63 | : 0), |
| 64 | ), |
| 65 | ), |
| 66 | ), |
| 67 | printClosingTagSuffix(child, options), |
| 68 | ]; |
| 69 | } |
| 70 | |
| 71 | return print(); |
| 72 | } |
| 73 | |
| 74 | function printBetweenLine(prevNode, nextNode) { |
| 75 | if (isTextLikeNode(prevNode) && isTextLikeNode(nextNode)) { |
no test coverage detected
searching dependent graphs…