我開始使用tsconfig.json角CLI構建--prod失敗tsconfig.json「noUnusedParameters」 SER爲true和角材料
的"noUnusedParameters": true
和"noUnusedLocals": true
選項,我覺得他們保持代碼的清潔是非常有用的突出顯示,因爲它們顯示未使用的導入和變量。
的問題是,當我嘗試建立一個督促包ng build --prod
命令我得到了很多的類型
ERROR in ng:///...../node_modules/@angular/material/form-field/typings/index.d.ts.MdFormField_Host.html (2,1): '$event' is declared but never used.
對角材料組件的錯誤和類似的錯誤對我個人的部件,例如
ERROR in ng:///.../src/app/components/my-comp/my-comp.component.html (5,9): '$event' is declared but never used.
一切工作正常,如果我關掉tsconfig.json的選擇,但我想知道是否有解決這個問題的一種方式。
我採用了棱角分明4.4.3和角材料2.0.0 beta.11