MCPcopy
hub / github.com/webpack/webpack / hasFile

Function hasFile

test/HotModuleReplacementPlugin.test.js:124–131  ·  view source on GitHub ↗
(/** @type {string} */ file)

Source from the content-addressed store, hash-verified

122 fs.writeFileSync(entryFile, `${++step}`, "utf8");
123 const updates = new Set();
124 const hasFile = (/** @type {string} */ file) => {
125 try {
126 fs.statSync(path.join(outputPath, file));
127 return true;
128 } catch (_err) {
129 return false;
130 }
131 };
132 const compiler = webpack({
133 mode: "development",
134 cache: false,

Callers 1

callbackFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected