Error AtlasError Documentation and Resolution

Vite HMR is not working because a file is imported with the wrong case

Vite detects a file change but the HMR is not working.

Vite sees the changed file, but Hot Module Replacement fails because the import path casing does not exactly match the real file path.

Vite detects a file change but the HMR is not workingdevelopment servers
Vite detects a file change but the HMR is not working.
  • A file is imported with different letter casing than the actual file on disk.
  • Cross-platform filesystem differences hide a casing mismatch during development.
  • Refactoring renamed a file but some imports still use stale casing.
  1. Update import paths so they exactly match the real filename casing.
  2. Search the codebase for inconsistent imports of the same file.
  3. Restart the dev server after correcting the import mismatch.
Vite: Troubleshooting
Vite HMR not working imported file different case: causes and fixes | Error Atlas