(nodeToDump: NodeToDump, memberNode: ts.TypeElement | ts.ClassElement)
| 479 | // Otherwise, only interested in symbols annotated with Valdi annotations |
| 480 | if (!nodeToDump.leadingComments) { |
| 481 | return false; |
| 482 | } |
| 483 | const comments = nodeToDump.leadingComments.text; |
| 484 | const hasMatch = hasNativeExportAnnotation(comments) || !!comments.match(/@Component|@ViewModel|@Context/g); |
| 485 | |
| 486 | return hasMatch; |
| 487 | } |
| 488 | |
| 489 | function shouldDumpNodeMember(nodeToDump: NodeToDump, memberNode: ts.TypeElement | ts.ClassElement): boolean { |
| 490 | const nodeComments = nodeToDump.leadingComments?.text; |
| 491 | if (!nodeComments) { |
| 492 | return false; |
| 493 | } |
| 494 | |
| 495 | if (nodeComments.match(/@NativeTemplateElement/)) { |
| 496 | return false; |
| 497 | } else if (nodeComments.match(/@Component/)) { |
| 498 | return !!(getNodeComments(memberNode)?.text ?? '').match(/@Action|@ConstructorOmitted/g); |
| 499 | } else if (hasGenerateOrExportAnnotation(nodeComments)) { |
no test coverage detected