(cwd: string, text: string)
| 2784 | } |
| 2785 | |
| 2786 | function normalizeSignature(cwd: string, text: string): string | null { |
| 2787 | const normalizedCwd = normalizePathName(cwd) |
| 2788 | const signature = text.replaceAll(normalizedCwd, ".").replaceAll(cwd, ".").replace(/\r\n?/g, "\n").replace( |
| 2789 | /[ \t]+$/gm, |
| 2790 | "" |
| 2791 | ).trim() |
| 2792 | return signature === "" ? null : signature |
| 2793 | } |
| 2794 | |
| 2795 | function displaySignature(text: string): string { |
| 2796 | return text.replace(/import\((?:"[^"]+"|'[^']+')\)\.([A-Za-z_$][A-Za-z0-9_$]*(?:\.[A-Za-z_$][A-Za-z0-9_$]*)*)/g, "$1") |
no test coverage detected