1.

Explain The Component Directory Structure Of Angular 4?

Answer»

Here are the elements which are present in the component directory structure anf modules: –

MODULE.ts- in this, the angular module is declared. @NgModule decorator is used which initializes the different aspects of angular applications. AppComponent is also declared in it.

COMPONENTS.ts- it simply DEFINES the components in angular and this is the place where the app-root sector is also defined. A TITLE attribute is also declared in the component.

Component.html- it is the TEMPLATE file of the application which represents the visual parts of our components.

Here are the elements which are present in the component directory structure anf modules: –

Module.ts- in this, the angular module is declared. @NgModule decorator is used which initializes the different aspects of angular applications. AppComponent is also declared in it.

Components.ts- it simply defines the components in angular and this is the place where the app-root sector is also defined. A title attribute is also declared in the component.

Component.html- it is the template file of the application which represents the visual parts of our components.



Discussion

No Comment Found