code: function encodePackageName(packageName) {
    // Thanks https://github.com/unpkg/npm-http-server/blob/master/modules/RegistryUtils.js
    // for scoped modules help
    let encodedPackageName;
    if (packageName[0] === "@") {
      // For the registry URL, the @ doesn't get URL encoded for some reason
      encodedPackageName = `@${encodeURIComponent(packageName.substring(1))}`;
    } else {
      encodedPackageName = encodeURIComponent(packageName);
    }
    return encodedPackageName;
  }
docs: Encodes the package name for use in a URL/HTTP request
  @param {string} packageName - the name of the package to encode