Я получил эту ошибку.Когда я создаю угловое универсальное приложение в файле server.ts.Это показывает мне ошибку внизу.
Версия приложения: 7.1.3
ZoneAwarePromise {
__zone_symbol__state: 0,
__zone_symbol__value:
TypeError: mitt is not a function
at new SitemapGenerator (E:\angular projects\run-app\dist\server.js:107657:19)
at E:\angular projects\run-app\dist\server.js:107577:25
at new ZoneAwarePromise (E:\angular projects\run-app\dist\server.js:1074:29)
at sitemap (E:\angular projects\run-app\dist\server.js:107575:12)
at E:\angular projects\run-app\dist\server.js:160:90
at ZoneDelegate.module.exports.ZoneDelegate.invokeTask (E:\angular projects\run-app\dist\server.js:604:31)
at Zone.module.exports.Zone.runTask (E:\angular projects\run-app\dist\server.js:371:47)
at module.exports.ZoneTask.invokeTask (E:\angular projects\run-app\dist\server.js:679:34)
at ZoneTask.invoke (E:\angular projects\run-app\dist\server.js:668:48)
at data.args.(anonymous function) (E:\angular projects\run-app\dist\server.js:1500:25) }
generating site map..3 http://localhost:8080
Unhandled Promise rejection: mitt is not a function ; Zone: <root> ; Task: fs.exists ; Value: TypeError: mitt is not a function
at new SitemapGenerator (E:\angular projects\run-app\dist\server.js:107657:19)
at E:\angular projects\run-app\dist\server.js:107577:25
at new ZoneAwarePromise (E:\angular projects\run-app\dist\server.js:1074:29)
at sitemap (E:\angular projects\run-app\dist\server.js:107575:12)
at E:\angular projects\run-app\dist\server.js:160:90
at ZoneDelegate.module.exports.ZoneDelegate.invokeTask (E:\angular projects\run-app\dist\server.js:604:31)
at Zone.module.exports.Zone.runTask (E:\angular projects\run-app\dist\server.js:371:47)
at module.exports.ZoneTask.invokeTask (E:\angular projects\run-app\dist\server.js:679:34)
at ZoneTask.invoke (E:\angular projects\run-app\dist\server.js:668:48)
at data.args.(anonymous function) (E:\angular projects\run-app\dist\server.js:1500:25) TypeError: mitt is not a function
at new SitemapGenerator (E:\angular projects\run-app\dist\server.js:107657:19)
at E:\angular projects\run-app\dist\server.js:107577:25
at new ZoneAwarePromise (E:\angular projects\run-app\dist\server.js:1074:29)
at sitemap (E:\angular projects\run-app\dist\server.js:107575:12)
at E:\angular projects\run-app\dist\server.js:160:90
at ZoneDelegate.module.exports.ZoneDelegate.invokeTask (E:\angular projects\run-app\dist\server.js:604:31)
at Zone.module.exports.Zone.runTask (E:\angular projects\run-app\dist\server.js:371:47)
at module.exports.ZoneTask.invokeTask (E:\angular projects\run-app\dist\server.js:679:34)
at ZoneTask.invoke (E:\angular projects\run-app\dist\server.js:668:48)
at data.args.(anonymous function) (E:\angular projects\run-app\dist\server.js:1500:25)
Пожалуйста, предоставьте мне лучшее решение.Я использую npm run build:prd
для угловых универсальных.