Vite
Vite failed because code requires non-strict mode
Vite encountered code that only works in sloppy mode, but Vite uses ESM and strict mode, so the code cannot be transformed safely.
Vite
Vite encountered code that only works in sloppy mode, but Vite uses ESM and strict mode, so the code cannot be transformed safely.
Observed message
[ERROR] With statements cannot be used with the "esm" output format due to strict mode
Why it happens
How to fix it
Official reference
Vite: TroubleshootingRelated errors
Explore more