我正在开发一个角度ssr应用程序。当我执行npm run dev:ssr
时,我得到以下错误
Your NodeJS application doesn't support 'perf_hooks'. TypeError: mod.require is not a function
A server error has occurred.
node exited with 1 code.
connect ECONNREFUSED 127.0.0.1:54208
我不知道是什么原因导致了这个错误?有人能帮我解决这个问题吗?非常感谢。
您正在使用ngx骨架加载程序吗?所有版本>2.2.1正在通过perf-marks包使用perf_hooks。
我又回到了2.2.1。并将尝试为加载器骨架找到不同的解决方案。