What You Know About Angular ?

Savindu Pasintha
2 min readJun 23, 2021

--

Environment create https://angular.io/guide/setup-local

see crud operation with API handling/http/Http json data read with observed arrays/handling/routing/Angular material/Event Handling/Data pass to UI

https://github.com/savindu-pasintha/Angular-Crud-Operation/tree/main/src/app

TypeScript Language

Typescript same as a javascript . when we write typescript code we can define all the codes/variable/method/class to SOME TYPE. Type script manly build for Object oriented programming for javascript.

Install node latest version.

Install Angular CLI as globaly

npm install -g @angular/cli

open project

ng new your_angular_app_name

go to project

cd your_angular_app_name

open web site in a browser

ng serve — open

create component in side the app folder

component folder inside have .html,.css,.ts files.

Html file for UI design Using HTML

Typescript (ts) file for create some methods , code for change the html.

Css file for styling

run cmd

ng g c component_name

create service folder

services folder used to create business logic or http method write backend API call Handling. when we create service folder we can communicate between Component .

run cmd

ng g s folder_name/file_name

After create file import the compont .ts file and then you can use and access this servicess class methods variables.

app.module.ts file is very important

This file inside we should import all the component/services/modules class name .

declatations:[] array inside to put all the compoent file import class name.

imports:[] array to put all the external moules classes imported names.

angular.json file

This file have angualr project to run all the dependancies and project details include.

If we install npm boostrap or any other Script or css files you can add to

style:[] array to add css file paths,

script:[] array to add javascript jquery or any other script files

That files we can globaly use whole the project that css or styles or javascript.

package.json

File inisde have all the installes node module dependancies names.

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

No responses yet

Write a response