core3-utils

@wixc3/typescript on Github

Home > @wixc3/typescript > getLeadingComments

getLeadingComments() function

A more regorges ts.getLeadingCommentRanges: Finds mid - statement comments as well

Signature:

export declare function getLeadingComments(node: ts.Node): Iterable<Comment>;

Parameters

Parameter Type Description
node ts.Node

Returns:

Iterable<Comment>

text - the content of the comment, without // or /* */