function normalizeSpecifierKey(specifierKey, baseURL) {
  // Ignore attempts to use the empty string as a specifier key
  if (specifierKey === '') {
    console.warn(`Invalid empty string specifier key.`);
    return undefined;
  }

  const url = tryURLLikeSpecifierParse(specifierKey, baseURL);
  if (url) {
    return url.href;
  }

  return specifierKey;
}
@param {string} specifierKey
@param {URL} baseURL
@returns {string | undefined}