no-zorro webpack prod打包报错

发布于 2022-09-07 22:23:51 字数 6974 浏览 21 评论 0

使用webpack打prod包的时候报错,但打dev包的时候正常,报错信息如下:

ERROR in node_modules\ng-zorro-antd\antd.d.ts.傻p.html(1,1442): : Expected 1 arguments, but got 3.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻bh.html(1,665): : Argument of type 'QueryList<NzOptionComponent>' is not assignable to parameter of type 'NzOptionComponent[]'.
[INFO]   Property 'includes' is missing in type 'QueryList<NzOptionComponent>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻bh.html(1,934): : Argument of type 'QueryList<NzOptionGroupComponent>' is not assignable to parameter of type 'NzOptionGroupComponent[]'.
[INFO]   Property 'includes' is missing in type 'QueryList<NzOptionGroupComponent>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻cd.html(1,188): : Property 'activeIndex' is private and only accessible within class 'NzMentionComponent'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻eg.html(1,938): : Expected 0 arguments, but got 1.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻ew.html(1,250): : Property 'isTitleString' is private and only accessible within class 'NzCardMetaComponent'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻ew.html(1,505): : Property 'isDescriptionString' is private and only accessible within class 'NzCardMetaComponent'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻gs.html(1,1597): : Argument of type 'CompatibleValue' is not assignable to parameter of type 'CandyDate[]'.
[INFO]   Type 'CandyDate' is not assignable to type 'CandyDate[]'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻gm.html(1,864): : Property 'nzAddOn' does not exist on type 'object'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻gm.html(1,750): : Property 'nzHideDisabledOptions' does not exist on type 'object'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻gm.html(1,810): : Property 'nzDefaultOpenValue' does not exist on type 'object'.
[ERROR] error Command failed with exit code 2.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻gm.html(1,598): : Property 'nzDisabledHours' does not exist on type 'object'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻gm.html(1,646): : Property 'nzDisabledMinutes' does not exist on type 'object'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻gm.html(1,698): : Property 'nzDisabledSeconds' does not exist on type 'object'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻gm.html(1,444): : Property 'nzFormat' does not exist on type 'object'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻gm.html(1,476): : Property 'nzHourStep' does not exist on type 'object'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻gm.html(1,514): : Property 'nzMinuteStep' does not exist on type 'object'.
[ERROR] error Command failed with exit code 1.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻gm.html(1,556): : Property 'nzSecondStep' does not exist on type 'object'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻hi.html(1,582): : Property 'span' does not exist on type 'NzListGrid'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,754): : Expected 0 arguments, but got 1.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,754): : Property 'onClickCloseBtn' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,1460): : Property 'isTemplateRef' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,1558): : Property 'isNonEmptyString' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,1841): : Property 'isTemplateRef' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,1943): : Property 'isNonEmptyString' is private and only accessible within class 'NzModalComponent<T, R>'.
[ERROR] error Command failed with exit code 1.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,2647): : Property 'getButtonCallableProp' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,2597): : Property 'getButtonCallableProp' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,2702): : Property 'getButtonCallableProp' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,2565): : Property 'onButtonClick' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,2976): : Property 'onClickOkCancel' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,3132): : Property 'onClickOkCancel' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,2266): : Property 'isTemplateRef' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,2366): : Property 'isNonEmptyString' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,2473): : Property 'isModalButtons' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,1776): : Property 'isComponent' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,4000): : Property 'isTemplateRef' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,4102): : Property 'isNonEmptyString' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,4405): : Property 'onClickOkCancel' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,4580): : Property 'onClickOkCancel' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,3642): : Property 'isTemplateRef' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,3740): : Property 'isNonEmptyString' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻iv.html(1,3935): : Property 'isComponent' is private and only accessible within class 'NzModalComponent<T, R>'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻jd.html(1,249): : Property 'nzShowSearch' does not exist on type 'NzCascaderComponent'.
[INFO] node_modules\ng-zorro-antd\antd.d.ts.傻jj.html(1,240): : Expected 1 arguments, but got 2.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

你的往事 2022-09-14 22:23:51

暂时是把严格校验屏蔽了,在tsconfig-aot.json文件中,将

"fullTemplateTypeCheck": true,

注释掉

无语# 2022-09-14 22:23:51

这报错信息写的一清二白的啊,挨个改了不就好了

dev 环境下打包好用那是因为 tsconfig.json 没有开启一些严格校验的配置,而 prod 会开启。

全部不再 2022-09-14 22:23:51

解决了吗?我也遇到了相同的问题,用的也是jhipster。如果解决了还望告知一下

场罚期间 2022-09-14 22:23:51

同问?解决了码?

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文