cd to your project and run,
> ng generate component "componentname"
ex: ng generate component shopping-cart
OR
> ng g c shopping-cart
(This will create new folder under "app" folder with name "shopping-cart" and create .html,.ts, .css. specs files.)
If you do not want to generate .spec file
> ng g c shopping-cart --skipTests true
If you want to create component in any specific folder under "app"
> ng g c ecommerce/shopping-cart
(you will get folder structure "app/ecommerce/shopping-cart")