(node: any)
| 725 | } |
| 726 | |
| 727 | function readStringLiteralValue(node: any): string | null { |
| 728 | if (!node) return null; |
| 729 | if (node.type === "StringLiteral" || node.type === "Literal") { |
| 730 | return typeof node.value === "string" ? node.value : null; |
| 731 | } |
| 732 | if (node.type === "TemplateLiteral" && (node.expressions?.length ?? 0) === 0) { |
| 733 | return node.quasis?.[0]?.value?.cooked ?? node.quasis?.[0]?.value?.raw ?? ""; |
| 734 | } |
| 735 | return null; |
| 736 | } |
| 737 | |
| 738 | function writeStringLiteralValue(node: any, value: string): boolean { |
| 739 | if (!node) return false; |
no outgoing calls
no test coverage detected