The generate command requires to be run in an Angular project?

谁说我不能喝 提交于 2019-12-11 10:57:40

问题


I'm wondering why I am getting this kind of message whenever I try to add a component in my angular project although I have Angular CLI installed in my project.


回答1:


As far as i know does ionic 3 dont create a angular.json, and that's what angular i looking for when you want to create for example a pipe.

When you want to create a pipe in ionic 3 just run ionic g pipe myPipe.

When you upgrade to ionic 4+ it will create a angular.json like a normal angular project would do.
See here ("@ionic/angular": "^4.7.1")

Then you can run all kind of ng command your used to from angular.



来源:https://stackoverflow.com/questions/58618391/the-generate-command-requires-to-be-run-in-an-angular-project

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!