This one is about the wrong error message. Duplicate of dynamic imports with variables in a dependency are not processed at all #6179. It gave me 504 outdated dep, so i purged cache and node_modules again and again to no avail.
A quick search on trusty stackoverflow indicated that. If it just gives me 404 i would know where to dig. When vite fails to resolve the path, it returns an erroneous error message (504.
Server responded with status 504 (outdated optimize dep) occurs when the server takes too long to respond to a request. One way to get them to show up is to start one remix vite app, stop it, and start another one. Learn how to update and optimize your angular application with the latest version of the 504 outdated optimize dep angular tool. The error failed to load resource:
I have also seen this very similar question: