I need to create a component without the folder. I am using Angular-Cli command ng g c testing
to create the component. But, the command creates an folder wrapper for the newly created component.
We can use ng generate component command to create component in sub-directory or specific folder.
The Angular framework allows us to use a component within another component and when we do so then it is called Angular Nested Components. The outside component is called the parent component and the inner component is called the child component.
You can use --flat
flag.
ng g c test --flat
For more information follow this link
flat = true | false
When true creates the new files at the top level of the current project.
Default: false
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With