Angular 5 Folder Structure - WebSecuritySpecialist
Hire Us For Secure Web Development and Security

Saturday, 3 March 2018

Angular 5 Folder Structure

When we install a new Angular 5 App it creates multiple files and folders like the screenshot below -


e2e stands for "end to end", we can write the end to end test here.
The end to end test is basically an automated test that simulates a real user.


In this folder, you can find all the third party libraries on which the application may depend.
This folder is purely for development.


This folder contains the actual source code for developers.

   - app folder
    Which contains all the “modules” and “components” of your application.
    Every application has at least one “module” and one “component”.

   - assets folder
    Where we can store static assets of our application for example images, css, js etc.

   - environment folder
    Where we can store configuration settings for different environments. Basically, this folder contains two files, file for the production environment.
        environment.ts file for the development environment.

favicon.ico is an icon file of your app.

index.html file contains our Angular application. All other pages are dynamically inserted into the page.

main.ts file is a TypeScript file. It is the starting point of our application.

pollyfills.ts file basically imports scripts required for running Angular app because angular framework uses the features of javascript which are not available in the current version of javascript supported by the most browser.

style.css is where we can add global styles for our applications.

test.ts file is used for setting the testing environment

angular-cli.json is standard configuration file of your application

editorconfig file is used when you are working in a team environment.

gitignore file is used for exporting files and folders to/from your git repository.

Karma.conf.js file is used to store the setting of Karma i.e. test cases.

package.json file is a standard file. It holds thelike name of the project, versions information, dependencies and dev-dependencies settings.

tsconfig.json file has a bunch of settings of TypeScript compiler.

tslint.json file checks your TypeScript code for readability, maintainability and functionality errors.

No comments:

Post a Comment