MCPcopy
hub / github.com/midudev/libros-programacion-gratis / isExternalUrl

Function isExternalUrl

web/scripts/check-links.mjs:228–230  ·  view source on GitHub ↗
(url)

Source from the content-addressed store, hash-verified

226}
227
228function isExternalUrl(url) {
229 return /^https?:\/\//i.test(url) || url.startsWith('//');
230}
231
232function normalizeExternalUrl(url) {
233 return url.startsWith('//') ? `https:${url}` : url;

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected