MCPcopy
hub / github.com/webpack/webpack / compareTo

Method compareTo

lib/Chunk.js:243–250  ·  view source on GitHub ↗

* Compares this chunk with another chunk. * @deprecated * @param {Chunk} otherChunk the chunk to compare with * @returns {-1 | 0 | 1} the comparison result

(otherChunk)

Source from the content-addressed store, hash-verified

241 * @returns {-1 | 0 | 1} the comparison result
242 */
243 compareTo(otherChunk) {
244 const chunkGraph = ChunkGraph.getChunkGraphForChunk(
245 this,
246 "Chunk.compareTo",
247 "DEP_WEBPACK_CHUNK_COMPARE_TO"
248 );
249 return chunkGraph.compareChunks(this, otherChunk);
250 }
251
252 /**
253 * Checks whether this chunk contains the module.

Callers 2

getChildIdsByOrdersMethod · 0.45

Calls 2

getChunkGraphForChunkMethod · 0.80
compareChunksMethod · 0.80

Tested by

no test coverage detected