(cwd: string, text: string)
| 2854 | } |
| 2855 | |
| 2856 | function normalizeSignature(cwd: string, text: string): string | null { |
| 2857 | const normalizedCwd = normalizePathName(cwd) |
| 2858 | const signature = text.replaceAll(normalizedCwd, ".").replaceAll(cwd, ".").replace(/\r\n?/g, "\n").replace( |
| 2859 | /[ \t]+$/gm, |
| 2860 | "" |
| 2861 | ).trim() |
| 2862 | return signature === "" ? null : signature |
| 2863 | } |
| 2864 | |
| 2865 | function displaySignature(text: string): string { |
| 2866 | return text.replace(/import\((?:"[^"]+"|'[^']+')\)\.([A-Za-z_$][A-Za-z0-9_$]*(?:\.[A-Za-z_$][A-Za-z0-9_$]*)*)/g, "$1") |
no test coverage detected