ionic4 笔记


1.

有时在页面中写ionic标签会报错“If 'ion-buttons' is an Angular component, then verify that it is part of this module.....”,解决方法是在当前页面的module.ts添加 schemas: [CUSTOM_ELEMENTS_SCHEMA]

2.

有时`ionic serve` 时会报这么一堆错误

“Module not found: Error: Can't resolve 'crypto' in 'E:\SAAS-App\node_modules\ws\lib'”

解决办法是

在`\node_modules@angular-devkit\build-angular\src\angular-cli-files\models\webpack-configs\browser.js`中 `node: false `替换为`node: {crypto:"empty",http:"empty",https:"empty",fs:"empty",path:"empty"},`

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容