用ionic 3开发也有一段时间了,现在总结下开发中遇到的报错,以及解决办法:
- ERROR DOMException: Failed to execute 'setAttribute' on 'Element': ')' is not a valid attribute name.
<button block ion-button class="m-0 buttom-btn" (click)="returnDeposit()" )>退押金</button>, 报错信息提示')'不是一个合法的属性,不能对dom元素执行setAttribute方法,这是检查下html是否有多写')'
- ERROR DOMException: Failed to execute 'setAttribute' on 'Element': ')' is not a valid attribute name.
同上
-
Native: tried calling plugins, but the plugin is not installed.或者 Uncaught (in promise)): plugin_not_installed
我在app.component.ts文件中使用了一些方法(来自一些原生插件)在platform.ready()外面调用,将这写方法调用写在platform.ready()里面就ok了
-
EXCEPTION: No provider for NavController
参考https://github.com/driftyco/ionic/issues/5543
持续更新中...