* Builds the web UI URL for a repository file at a given branch. Azure DevOps * file links use `{repoWebUrl}?path={path}&version=GB{branch}` (GB = Git Branch).
( repoWebUrl: string | undefined, branch: string, path: string )
| 829 | * file links use `{repoWebUrl}?path={path}&version=GB{branch}` (GB = Git Branch). |
| 830 | */ |
| 831 | function buildFileSourceUrl( |
| 832 | repoWebUrl: string | undefined, |
| 833 | branch: string, |
| 834 | path: string |
| 835 | ): string | undefined { |
| 836 | if (!repoWebUrl) return undefined |
| 837 | return `${repoWebUrl}?path=${encodeURIComponent(path)}&version=GB${encodeURIComponent(branch)}` |
| 838 | } |
| 839 | |
| 840 | /** |
| 841 | * Builds a deferred stub for a repository file. Content is empty and fetched |
no outgoing calls
no test coverage detected