(url: string)
| 6 | import { createSearchSelectContext, INPUT_THEME, note, toEnvKey } from './utils.js'; |
| 7 | |
| 8 | function githubApiBase(url: string): string { |
| 9 | try { |
| 10 | const u = new URL(url); |
| 11 | if (u.hostname === 'github.com') { |
| 12 | return 'https://api.github.com'; |
| 13 | } |
| 14 | return `${u.protocol}//${u.hostname}/api/v3`; |
| 15 | } catch { |
| 16 | return 'https://api.github.com'; |
| 17 | } |
| 18 | } |
| 19 | |
| 20 | type SearchOption = { name: string; value: string }; |
| 21 | type GitHubSearchType = 'org' | 'user' | 'repo'; |
no outgoing calls
no test coverage detected