vite8.3.81.3 MB
Shown as plain text from the published tarball, after apm checked it against the version's checksum. Nothing in it runs on this page.
if (sourcefile === escapedFilename && sourcemapList[mapIndex]) return sourcemapList[mapIndex++];
else return null;
});
if (!map.file) delete map.file;
map.sources = map.sources.map((source) => source ? unescapeToLinuxLikePath(source) : source);
map.file = filename;
return map;
}
function unique(arr) {
return [...new Set(arr)];
}
/**
* Returns resolved localhost address when `dns.lookup` result differs from DNS
*
* `dns.lookup` result is same when defaultResultOrder is `verbatim`.
* Even if defaultResultOrder is `ipv4first`, `dns.lookup` result maybe same.
* For example, when IPv6 is not supported on that machine/network.
*/
function getLocalhostAddressIfDiffersFromDNS() {
if (promises.getDefaultResultOrder && promises.getDefaultResultOrder() === "verbatim") return;
return Promise.all([promises.lookup("localhost"), promises.lookup("localhost", { verbatim: true })]).then(([nodeResult, dnsResult]) => {
return nodeResult.family === dnsResult.family && nodeResult.address === dnsResult.address ? void 0 : nodeResult.address;
});
}
function diffDnsOrderChange(oldUrls, newUrls) {
return !(oldUrls === newUrls || oldUrls && newUrls && arrayEqual(oldUrls.local, newUrls.local) && arrayEqual(oldUrls.network, newUrls.network));
}
async function resolveHostname(optionsHost) {
let host;
if (optionsHost === void 0 || optionsHost === false) host = "localhost";
else if (optionsHost === true) host = void 0;
else host = optionsHost;
let name = host === void 0 || wildcardHosts.has(host) ? "localhost" : host;
if (host === "localhost") {
const localhostAddr = await getLocalhostAddressIfDiffersFromDNS();
if (localhostAddr) name = localhostAddr;
}
return {
host,
name
};
This file is 1.3 MB, over the 1.0 MB the full view shows, so apm shows the lines around the cited one. Lines longer than 4 kB are cut.