ts-api-utils - v3.0.0-rc.1
    Preparing search index...

    Type Alias ForEachCommentCallback

    ForEachCommentCallback: (fullText: string, comment: ts.CommentRange) => void

    Callback type used for forEachComment.

    Type Declaration

      • (fullText: string, comment: ts.CommentRange): void
      • Parameters

        • fullText: string

          Full parsed text of the comment.

        • comment: ts.CommentRange

          Text range of the comment in its file.

        Returns void

    let onComment: ForEachCommentCallback = (fullText, comment) => {
    console.log(`Found comment at position ${comment.pos}: '${fullText}'.`);
    };