I’m trying to set up a custom card but getting lots of 404 errors in the browser from webpack dependencies, like these:
GET http://homeassistant.local:8123/unknown/src/scoped-custom-element-registry.js 404 (Not Found)
GET http://homeassistant.local:8123/unknown/src/lit-html.ts 404 (Not Found)
I’m guessing it’s something to do with this section of code in frontend/build-scripts/webpack.cjs but I don’t know enough about the script builder to resolve the problem.
// Source URLs are unknown for dependencies, so we use a relative URL with a
// non - existent top directory. This results in a clean source tree in browser
// dev tools, and they stay happy getting 404s with valid requests.
return `/unknown${path.resolve("/", info.resourcePath)}`;`
