The problem seems to be with esbuild's latest version 0.24.1
Downgrading to 0.24.0 will solve the error for now npm i -D [email protected]
npm i -D [email protected]