TypeError: Cannot read properties of undefined (reading 'startsWith')

Рейтинг: -1Ответов: 1Опубликовано: 16.02.2023
TypeError: Cannot read properties of undefined (reading 'startsWith')
    at checkManaged (/home/mikhail/Документы/Work/Labr/node_modules/webpack/lib/FileSystemInfo.js:2030:14)
    at captureNonManaged (/home/mikhail/Документы/Work/Labr/node_modules/webpack/lib/FileSystemInfo.js:2044:10)
    at FileSystemInfo.createSnapshot (/home/mikhail/Документы/Work/Labr/node_modules/webpack/lib/FileSystemInfo.js:2127:25)
    at /home/mikhail/Документы/Work/Labr/node_modules/html-webpack-plugin/lib/file-watcher-api.js:14:36
    at new Promise (<anonymous>)
    at Object.createSnapshot (/home/mikhail/Документы/Work/Labr/node_modules/html-webpack-plugin/lib/file-watcher-api.js:13:10)
    at /home/mikhail/Документы/Work/Labr/node_modules/html-webpack-plugin/lib/cached-child-compiler.js:219:35
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
    at runNextTicks (node:internal/process/task_queues:64:3)
    at process.processImmediate (node:internal/timers:447:9)

Node.js v18.14.0

Ответы

▲ 0
// Locate this file  
node_modules/.pnpm/html-webpack-plugin@5.5.0_webpack@5.75.0/node_modules/html-webpack-plugin/lib/cached-child-compiler.js

// Find this code  
compiledEntriesPromise.then((childCompilationResult) => {  
    // Add code, output error  
    if(childCompilationResult.error) {  
        console.error("Compilation error", childCompilationResult.error)  
    }  
    ...  
})