gpt4 book ai didi

棱 Angular 分明。 [HMR] 无法应用更新。需要做一个完整的重新加载

转载 作者:行者123 更新时间:2023-12-04 17:36:27 35 4
gpt4 key购买 nike

我将 HMR ( stories configure hmr ) 添加到我的 Angular 项目中,但不是热重载,而是将其完全重载。

更新到angular 8,问题没有解决。

[HMR] Cannot apply update. Need to do a full reload!
...
[HMR] Error: Aborted because ./node_modules/raw-loader/index.js!./src/app/components/tabs/remark/remark.component.html is not accepted
Update propagation: ./node_modules/raw-loader/index.js!./src/app/components/tabs/remark/remark.component.html -> ./src/app/components/tabs/remark/remark.component.ts -> ./src/app/app.module.ts -> ./src/main.ts -> 0
at hotApply (http://localhost:4201/runtime.js:525:30)
at http://localhost:4201/runtime.js:363:22
at ZoneDelegate.push../node_modules/zone.js/dist/zone.js.ZoneDelegate.invoke (http://localhost:4201/polyfills.js:3516:26)
at Zone.push../node_modules/zone.js/dist/zone.js.Zone.run (http://localhost:4201/polyfills.js:3275:43)
at http://localhost:4201/polyfills.js:4035:34
at ZoneDelegate.push../node_modules/zone.js/dist/zone.js.ZoneDelegate.invokeTask (http://localhost:4201/polyfills.js:3548:31)
at Zone.push../node_modules/zone.js/dist/zone.js.Zone.runTask (http://localhost:4201/polyfills.js:3320:47)
at drainMicroTaskQueue (http://localhost:4201/polyfills.js:3726:35)
  • 列表项
  • 最佳答案

    我曾经像那样运行我的应用程序ng serve --hmr
    一旦我开始使用 hmr 配置ng serve -c hmr
    HMR 开始工作。

    您应该确保在 angular.json 中启用了 hmr和 environment.ts

    关于棱 Angular 分明。 [HMR] 无法应用更新。需要做一个完整的重新加载,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56537929/

    35 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com