* Add handleTemplateLiteralComment helper function. * Fix handleTemplateLiteralComment function. * Extend handleTemplateLiteralComment to deal with trailing comments 🚀. * Add test. * Make handle comments function naming more consistent, fix merge conflicts. * Update tests. * Add better comment injection in Template Literal. * Pass options to attach function. * Update tests to match new implementation. * Fix let -> var in findExpressionIndexForComment for NodeJS v4. * Reorder after merge conflicts. * Drop old tests for dangling arrays. * Replace redundant conditional by a boolean 🚀. * Refactor implementation.
13 lines
104 B
JavaScript
13 lines
104 B
JavaScript
`
|
|
${a // comment
|
|
}
|
|
|
|
${b /* comment */}
|
|
|
|
${/* comment */ c /* comment */}
|
|
|
|
${// comment
|
|
d //comment
|
|
};
|
|
`
|