我收到此错误消息:
无法绑定到'primary',因为它不是'button'的已知属性。
我正在使用yo aspnetcore-spa
角度发生器。 BrowserAnimationsModule
和ButtonsModule
在我的app.module中导入并在导入中注册。我的所有角度和剑道包都是最新版本。
此外,当我从[primary]="true"
中删除<button>
时,错误消失了。之后,我再次添加[primary]="true"
(没有刷新页面,HMR重建)它工作正常。而且,如果我刷新页面,错误会再次出现。
有解决方案吗
提前致谢。
你的按钮看起来应该是这样的:
<button kendoButton [primary]="true">Primary</button>
别忘了'kendoButton'。
qazxsw poi不需要括号,尽管他们的例子说它确实如此。尝试:
Primary
确保在模块中导入ButtonsModule
<button kendoButton primary="true">Primary</button>