MCPcopy
hub / github.com/webpack/webpack / getEtag

Method getEtag

lib/optimize/RealContentHashPlugin.js:387–394  ·  view source on GitHub ↗
(asset)

Source from the content-addressed store, hash-verified

385 * @returns {Etag} etag
386 */
387 const getEtag = (asset) =>
388 cacheGenerate.mergeEtags(
389 cacheGenerate.getLazyHashedEtag(asset.source),
390 Array.from(
391 /** @type {Hashes} */ (asset.referencedHashes),
392 (hash) => hashToNewHash.get(hash)
393 ).join("|")
394 );
395 /**
396 * Compute new content.
397 * @param {AssetInfoForRealContentHash} asset asset info

Callers

nothing calls this directly

Calls 3

mergeEtagsMethod · 0.80
getLazyHashedEtagMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected