SlideShare a Scribd company logo
1 of 27
Download to read offline
ANGULAR 5
By: Abhishek Mallick
WE WILL DISCUSS ABOUT
• Introduction
• Evolution Timeline
• Some Syntax AngularJS vs Angular 5
• Angular 5 start-up
– Angular 5 setup
– Angular 5 create new project
– New project structure
– Special Instruction
• Angular 5 elements
– Components
– Interpolation, Property Binding & Event Binding
– Route
– Services
• Angular 5 Deployment
INTRODUCTION
• Angular is a
– JavaScript-based
– Open-source
– Front-end web application framework
– Mainly maintained by Google
– And by a community of individuals and corporations
– To address many of the challenges encountered in developing
single-page applications
EVOLUTION TIMELINE
2012
2014
2016
2017
2018
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
AngularJS Angular 2 Angular 4 Angular 5 Angular 6
SOME SYNTAX ANGULARJS VS ANGULAR 5
Syntax AngularJS Angular 5
Model binding ng-model [(ngModel)]
Value Binding ng-value [value]
Click Binding ng-click (click)
Scope creation $scope Not needed
Repetition ng-repeat *ngFor
ANGULAR 5 START-UP (SETUP)
• Open command line interface
• Type command to install angular 5 at global level
– $ npm install @angular/cli -g
• Once the installation is over to check the version of Angular
use command
– $ ng -v
• If you see an output similar to this the installation is over
– Angular CLI: 1.6.8
Node: 8.9.1
OS: win32 x64
Angular:
…
ANGULAR 5 START-UP (CREATE NEW PROJECT)
• Open command prompt interface to the folder path
• Run the command to generate the angular structure inside the folder:
– $ ng new <project_name> –style=scss –routing
• Here in above code we are creating a new project with style support for
scss and routing enabled
• Now get inside the project name folder <project_name> by command
– $ cd <project_name>
• Now it’s time to run the default project created using command
– $ ng serve
• Now test your first application by opening the browser and opening url
mentioned which running the above command (default
http://localhost:4200)
ANGULAR 5 START-UP (CREATE NEW PROJECT)
ANGULAR 5 START-UP (PROJECT STRUCTURE)
ANGULAR 5 START-UP (SPECIAL INSTRUCTION)
• To do the changes we will do all our changes inside “src”
folder
ANGULAR 5 ELEMENTS (COMPONENTS)
• Angular components are considered as the basic building
blocks of angular app.
• Angular components can be found inside “/src/app” folder
• Angular components is made up of:
– A component decorator, which help to set CSS, animations and many
more
– Imports needed by the component to work
– A Class (here lies the component’s logic)
ANGULAR 5 ELEMENTS (COMPONENTS)
• Open the cmd in the <project_name> location
• Type the command
– $ ng generate component <component_name>
– You can also do this by using command
– $ ng g c <component_name>
– Example:
• $ ng g c home
• The above command will generate the component with other files as:
• create src/app/home/home.component.html (23 bytes)
create src/app/home/home.component.spec.ts (614 bytes)
create src/app/home/home.component.ts (262 bytes)
create src/app/home/home.component.scss (0 bytes)
update src/app/app.module.ts (467 bytes)
• It also maps the new component in the app.module.ts as from above.
ANGULAR 5 ELEMENTS (COMPONENTS)
• Now if you check the above files let us go through each
one by one:
– home.component.html : This file contains the html for the home
component. All the html changes need to be changed for this
component needs to be added in this file.
– home.component.ts : This file contains the logic need to be
performed for this component under the class
“HomeComponent” inside.
– home.component.scss : This file contains the CSS styling that
needs to be added for the component.
ANGULAR 5 ELEMENTS (INTERPOLATION)
• When we change some property from the component
class to template we use interpolation.
ANGULAR 5 ELEMENTS (INTERPOLATION)
• Example at:
https://abhishekmallickblog.wordpress.com/2018/02/20/
angular-5-interpolation-property-binding-event-binding/
ANGULAR 5 ELEMENTS (PROPERTY BINDING)
• Binding the properties of the html element with the code
in the class
ANGULAR 5 ELEMENTS (PROPERTY BINDING)
• Example at:
https://abhishekmallickblog.wordpress.com/2018/02/20/
angular-5-interpolation-property-binding-event-binding/
ANGULAR 5 ELEMENTS (EVENT BINDING)
• Say you want to take a data and set data from and to
an input box using component class then you use Two-
way Binding
ANGULAR 5 ELEMENTS (EVENT BINDING)
• Example at:
https://abhishekmallickblog.wordpress.com/2018/02/20/
angular-5-interpolation-property-binding-event-binding/
ANGULAR 5 ELEMENTS (ROUTE)
• Route is navigating through the multiple screens of the
app.
ANGULAR 5 ELEMENTS (ROUTE)
• Example at:
https://abhishekmallickblog.wordpress.com/2018/02/20/
angular-5-route/
ANGULAR 5 ELEMENTS (SERVICES)
• Services are class in Angular 5 which are used to provide
common features or variables to multiple modules of the
app.
ANGULAR 5 ELEMENTS (SERVICES)
• Example at:
https://abhishekmallickblog.wordpress.com/2018/03/25/
angular-5-services/
ANGULAR 5 DEPLOYMENT
• Normal build
– $ ng build
– after it executes (might 5 to 15 min) you can see a folder ”/dist”
• Production build
– $ ng build –prod
– after it executes (might 5 to 15 min) you can see a folder ”/dist”
• Let us see the difference between both
AT LAST OF THEORY
• As you can see from the evolution of Angular from 2012
till today, there been multiple iterations. This can help
you solve a problem and not the only solution.
• So what must be in mind is
“These are only tools which can only enable
you to solve a problem and only limited what
you want to use it for” – Abhishek Mallick
REFERENCE
• https://abhishekmallickblog.wordpress.com/2018/02/20/l
et-us-start-with-angular-5/
• https://angular.io/docs
THANK YOU FOR BEING SUCH A GREAT FOLKS

More Related Content

What's hot

Jenkins Continuous Delivery
Jenkins Continuous DeliveryJenkins Continuous Delivery
Jenkins Continuous DeliveryJadson Santos
 
Angular4 getting started
Angular4 getting startedAngular4 getting started
Angular4 getting startedTejinderMakkar
 
What Is Angular 2 | Angular 2 Tutorial For Beginners | Angular Training | Edu...
What Is Angular 2 | Angular 2 Tutorial For Beginners | Angular Training | Edu...What Is Angular 2 | Angular 2 Tutorial For Beginners | Angular Training | Edu...
What Is Angular 2 | Angular 2 Tutorial For Beginners | Angular Training | Edu...Edureka!
 
Alloy Simple App Demonstration
Alloy Simple App DemonstrationAlloy Simple App Demonstration
Alloy Simple App DemonstrationAaron Saunders
 
Appcelerator Titanium Alloy
Appcelerator Titanium Alloy Appcelerator Titanium Alloy
Appcelerator Titanium Alloy karthi-anubavam
 
Angular App Presentation
Angular App PresentationAngular App Presentation
Angular App PresentationElizabeth Long
 
Dive into Angular, part 4: Angular 2.0
Dive into Angular, part 4: Angular 2.0Dive into Angular, part 4: Angular 2.0
Dive into Angular, part 4: Angular 2.0Oleksii Prohonnyi
 
Angular 6 - The Complete Guide
Angular 6 - The Complete GuideAngular 6 - The Complete Guide
Angular 6 - The Complete GuideSam Dias
 
Angular 4 Introduction Tutorial
Angular 4 Introduction TutorialAngular 4 Introduction Tutorial
Angular 4 Introduction TutorialScott Lee
 
Angular 4 Tutorial | What's New In Angular 4 | Angular Training | Edureka
Angular 4 Tutorial | What's New In Angular 4 | Angular Training | EdurekaAngular 4 Tutorial | What's New In Angular 4 | Angular Training | Edureka
Angular 4 Tutorial | What's New In Angular 4 | Angular Training | EdurekaEdureka!
 
Angular, the New Angular JS
Angular, the New Angular JSAngular, the New Angular JS
Angular, the New Angular JSKenzan
 
Developing a Demo Application with Angular 4 - J2I
Developing a Demo Application with Angular 4 - J2IDeveloping a Demo Application with Angular 4 - J2I
Developing a Demo Application with Angular 4 - J2INader Debbabi
 
Introduction for Master Class "Amazing Reactive Forms"
Introduction for Master Class "Amazing Reactive Forms"Introduction for Master Class "Amazing Reactive Forms"
Introduction for Master Class "Amazing Reactive Forms"Fabio Biondi
 
Learn Angular 9/8 In Easy Steps
Learn Angular 9/8 In Easy Steps Learn Angular 9/8 In Easy Steps
Learn Angular 9/8 In Easy Steps Ahmed Bouchefra
 
React Native - Getting Started
React Native - Getting StartedReact Native - Getting Started
React Native - Getting StartedTracy Lee
 
The Ultimate Getting Started with Angular Workshop - Devoxx UK 2017
The Ultimate Getting Started with Angular Workshop - Devoxx UK 2017The Ultimate Getting Started with Angular Workshop - Devoxx UK 2017
The Ultimate Getting Started with Angular Workshop - Devoxx UK 2017Matt Raible
 

What's hot (20)

Jenkins Continuous Delivery
Jenkins Continuous DeliveryJenkins Continuous Delivery
Jenkins Continuous Delivery
 
Angular4 getting started
Angular4 getting startedAngular4 getting started
Angular4 getting started
 
ReactJS.NET
ReactJS.NETReactJS.NET
ReactJS.NET
 
What Is Angular 2 | Angular 2 Tutorial For Beginners | Angular Training | Edu...
What Is Angular 2 | Angular 2 Tutorial For Beginners | Angular Training | Edu...What Is Angular 2 | Angular 2 Tutorial For Beginners | Angular Training | Edu...
What Is Angular 2 | Angular 2 Tutorial For Beginners | Angular Training | Edu...
 
Alloy Simple App Demonstration
Alloy Simple App DemonstrationAlloy Simple App Demonstration
Alloy Simple App Demonstration
 
Appcelerator Titanium Alloy
Appcelerator Titanium Alloy Appcelerator Titanium Alloy
Appcelerator Titanium Alloy
 
Angular App Presentation
Angular App PresentationAngular App Presentation
Angular App Presentation
 
Dive into Angular, part 4: Angular 2.0
Dive into Angular, part 4: Angular 2.0Dive into Angular, part 4: Angular 2.0
Dive into Angular, part 4: Angular 2.0
 
Angular 6 - The Complete Guide
Angular 6 - The Complete GuideAngular 6 - The Complete Guide
Angular 6 - The Complete Guide
 
Angular 4 Introduction Tutorial
Angular 4 Introduction TutorialAngular 4 Introduction Tutorial
Angular 4 Introduction Tutorial
 
Angular 4 Tutorial | What's New In Angular 4 | Angular Training | Edureka
Angular 4 Tutorial | What's New In Angular 4 | Angular Training | EdurekaAngular 4 Tutorial | What's New In Angular 4 | Angular Training | Edureka
Angular 4 Tutorial | What's New In Angular 4 | Angular Training | Edureka
 
Angular 9 New features
Angular 9 New featuresAngular 9 New features
Angular 9 New features
 
Angular 2 - An Introduction
Angular 2 - An IntroductionAngular 2 - An Introduction
Angular 2 - An Introduction
 
Angular, the New Angular JS
Angular, the New Angular JSAngular, the New Angular JS
Angular, the New Angular JS
 
Developing a Demo Application with Angular 4 - J2I
Developing a Demo Application with Angular 4 - J2IDeveloping a Demo Application with Angular 4 - J2I
Developing a Demo Application with Angular 4 - J2I
 
Introduction for Master Class "Amazing Reactive Forms"
Introduction for Master Class "Amazing Reactive Forms"Introduction for Master Class "Amazing Reactive Forms"
Introduction for Master Class "Amazing Reactive Forms"
 
Learn Angular 9/8 In Easy Steps
Learn Angular 9/8 In Easy Steps Learn Angular 9/8 In Easy Steps
Learn Angular 9/8 In Easy Steps
 
React Native - Getting Started
React Native - Getting StartedReact Native - Getting Started
React Native - Getting Started
 
Angular 9
Angular 9 Angular 9
Angular 9
 
The Ultimate Getting Started with Angular Workshop - Devoxx UK 2017
The Ultimate Getting Started with Angular Workshop - Devoxx UK 2017The Ultimate Getting Started with Angular Workshop - Devoxx UK 2017
The Ultimate Getting Started with Angular Workshop - Devoxx UK 2017
 

Similar to Say hello world with angular 5

Web worker in your angular application
Web worker in your angular applicationWeb worker in your angular application
Web worker in your angular applicationSuresh Patidar
 
Angular 6 Form Validation with Material
Angular 6 Form Validation with MaterialAngular 6 Form Validation with Material
Angular 6 Form Validation with MaterialMalika Munaweera
 
Introduction to angular with a simple but complete project
Introduction to angular with a simple but complete projectIntroduction to angular with a simple but complete project
Introduction to angular with a simple but complete projectJadson Santos
 
Angular kickstart slideshare
Angular kickstart   slideshareAngular kickstart   slideshare
Angular kickstart slideshareSaleemMalik52
 
End to-End SPA Development Using ASP.NET and AngularJS
End to-End SPA Development Using ASP.NET and AngularJSEnd to-End SPA Development Using ASP.NET and AngularJS
End to-End SPA Development Using ASP.NET and AngularJSGil Fink
 
Webcomponents are your frameworks best friend
Webcomponents are your frameworks best friendWebcomponents are your frameworks best friend
Webcomponents are your frameworks best friendFilip Bruun Bech-Larsen
 
Stencil the time for vanilla web components has arrived
Stencil the time for vanilla web components has arrivedStencil the time for vanilla web components has arrived
Stencil the time for vanilla web components has arrivedGil Fink
 
Quick introduction to Angular 4 for AngularJS 1.5 developers
Quick introduction to Angular 4 for AngularJS 1.5 developersQuick introduction to Angular 4 for AngularJS 1.5 developers
Quick introduction to Angular 4 for AngularJS 1.5 developersPaweł Żurowski
 
AngularJS Beginners Workshop
AngularJS Beginners WorkshopAngularJS Beginners Workshop
AngularJS Beginners WorkshopSathish VJ
 
TechEvent 2019: Nachhaltige Client-Architekturen mit Angular Elements; Thomas...
TechEvent 2019: Nachhaltige Client-Architekturen mit Angular Elements; Thomas...TechEvent 2019: Nachhaltige Client-Architekturen mit Angular Elements; Thomas...
TechEvent 2019: Nachhaltige Client-Architekturen mit Angular Elements; Thomas...Trivadis
 
Angular - Chapter 3 - Components
Angular - Chapter 3 - ComponentsAngular - Chapter 3 - Components
Angular - Chapter 3 - ComponentsWebStackAcademy
 
Angular Interview Questions-PDF.pdf
Angular Interview Questions-PDF.pdfAngular Interview Questions-PDF.pdf
Angular Interview Questions-PDF.pdfJohnLeo57
 
Angular 6 Training with project in hyderabad india
Angular 6 Training with project in hyderabad indiaAngular 6 Training with project in hyderabad india
Angular 6 Training with project in hyderabad indiaphp2ranjan
 
Angular elements - embed your angular components EVERYWHERE
Angular elements - embed your angular components EVERYWHEREAngular elements - embed your angular components EVERYWHERE
Angular elements - embed your angular components EVERYWHERENadav Mary
 

Similar to Say hello world with angular 5 (20)

Angular IO
Angular IOAngular IO
Angular IO
 
Web worker in your angular application
Web worker in your angular applicationWeb worker in your angular application
Web worker in your angular application
 
Angular 6 Form Validation with Material
Angular 6 Form Validation with MaterialAngular 6 Form Validation with Material
Angular 6 Form Validation with Material
 
Introduction to angular with a simple but complete project
Introduction to angular with a simple but complete projectIntroduction to angular with a simple but complete project
Introduction to angular with a simple but complete project
 
Angular kickstart slideshare
Angular kickstart   slideshareAngular kickstart   slideshare
Angular kickstart slideshare
 
Angular 2.0
Angular  2.0Angular  2.0
Angular 2.0
 
Why choose Angular 6?
Why choose Angular 6?Why choose Angular 6?
Why choose Angular 6?
 
End to-End SPA Development Using ASP.NET and AngularJS
End to-End SPA Development Using ASP.NET and AngularJSEnd to-End SPA Development Using ASP.NET and AngularJS
End to-End SPA Development Using ASP.NET and AngularJS
 
An Overview of Angular 4
An Overview of Angular 4 An Overview of Angular 4
An Overview of Angular 4
 
Webcomponents are your frameworks best friend
Webcomponents are your frameworks best friendWebcomponents are your frameworks best friend
Webcomponents are your frameworks best friend
 
mean stack
mean stackmean stack
mean stack
 
Stencil the time for vanilla web components has arrived
Stencil the time for vanilla web components has arrivedStencil the time for vanilla web components has arrived
Stencil the time for vanilla web components has arrived
 
Quick introduction to Angular 4 for AngularJS 1.5 developers
Quick introduction to Angular 4 for AngularJS 1.5 developersQuick introduction to Angular 4 for AngularJS 1.5 developers
Quick introduction to Angular 4 for AngularJS 1.5 developers
 
AngularJS Beginners Workshop
AngularJS Beginners WorkshopAngularJS Beginners Workshop
AngularJS Beginners Workshop
 
TechEvent 2019: Nachhaltige Client-Architekturen mit Angular Elements; Thomas...
TechEvent 2019: Nachhaltige Client-Architekturen mit Angular Elements; Thomas...TechEvent 2019: Nachhaltige Client-Architekturen mit Angular Elements; Thomas...
TechEvent 2019: Nachhaltige Client-Architekturen mit Angular Elements; Thomas...
 
Angular - Chapter 3 - Components
Angular - Chapter 3 - ComponentsAngular - Chapter 3 - Components
Angular - Chapter 3 - Components
 
Angular Interview Questions-PDF.pdf
Angular Interview Questions-PDF.pdfAngular Interview Questions-PDF.pdf
Angular Interview Questions-PDF.pdf
 
Angular 6 Training with project in hyderabad india
Angular 6 Training with project in hyderabad indiaAngular 6 Training with project in hyderabad india
Angular 6 Training with project in hyderabad india
 
AngularJS
AngularJSAngularJS
AngularJS
 
Angular elements - embed your angular components EVERYWHERE
Angular elements - embed your angular components EVERYWHEREAngular elements - embed your angular components EVERYWHERE
Angular elements - embed your angular components EVERYWHERE
 

Recently uploaded

Understanding Flamingo - DeepMind's VLM Architecture
Understanding Flamingo - DeepMind's VLM ArchitectureUnderstanding Flamingo - DeepMind's VLM Architecture
Understanding Flamingo - DeepMind's VLM Architecturerahul_net
 
CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceBrainSell Technologies
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfAlina Yurenko
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Natan Silnitsky
 
Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Velvetech LLC
 
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company OdishaBalasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odishasmiwainfosol
 
Xen Safety Embedded OSS Summit April 2024 v4.pdf
Xen Safety Embedded OSS Summit April 2024 v4.pdfXen Safety Embedded OSS Summit April 2024 v4.pdf
Xen Safety Embedded OSS Summit April 2024 v4.pdfStefano Stabellini
 
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...OnePlan Solutions
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanyChristoph Pohl
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesŁukasz Chruściel
 
Large Language Models for Test Case Evolution and Repair
Large Language Models for Test Case Evolution and RepairLarge Language Models for Test Case Evolution and Repair
Large Language Models for Test Case Evolution and RepairLionel Briand
 
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Cizo Technology Services
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEEVICTOR MAESTRE RAMIREZ
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Matt Ray
 
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...OnePlan Solutions
 
SpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at RuntimeSpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at Runtimeandrehoraa
 
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Angel Borroy López
 
Call Us🔝>༒+91-9711147426⇛Call In girls karol bagh (Delhi)
Call Us🔝>༒+91-9711147426⇛Call In girls karol bagh (Delhi)Call Us🔝>༒+91-9711147426⇛Call In girls karol bagh (Delhi)
Call Us🔝>༒+91-9711147426⇛Call In girls karol bagh (Delhi)jennyeacort
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsAhmed Mohamed
 

Recently uploaded (20)

Understanding Flamingo - DeepMind's VLM Architecture
Understanding Flamingo - DeepMind's VLM ArchitectureUnderstanding Flamingo - DeepMind's VLM Architecture
Understanding Flamingo - DeepMind's VLM Architecture
 
CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. Salesforce
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
 
Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...
 
Advantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your BusinessAdvantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your Business
 
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company OdishaBalasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
 
Xen Safety Embedded OSS Summit April 2024 v4.pdf
Xen Safety Embedded OSS Summit April 2024 v4.pdfXen Safety Embedded OSS Summit April 2024 v4.pdf
Xen Safety Embedded OSS Summit April 2024 v4.pdf
 
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
Maximizing Efficiency and Profitability with OnePlan’s Professional Service A...
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New Features
 
Large Language Models for Test Case Evolution and Repair
Large Language Models for Test Case Evolution and RepairLarge Language Models for Test Case Evolution and Repair
Large Language Models for Test Case Evolution and Repair
 
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEE
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
 
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
 
SpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at RuntimeSpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at Runtime
 
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
Alfresco TTL#157 - Troubleshooting Made Easy: Deciphering Alfresco mTLS Confi...
 
Call Us🔝>༒+91-9711147426⇛Call In girls karol bagh (Delhi)
Call Us🔝>༒+91-9711147426⇛Call In girls karol bagh (Delhi)Call Us🔝>༒+91-9711147426⇛Call In girls karol bagh (Delhi)
Call Us🔝>༒+91-9711147426⇛Call In girls karol bagh (Delhi)
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML Diagrams
 

Say hello world with angular 5

  • 2. WE WILL DISCUSS ABOUT • Introduction • Evolution Timeline • Some Syntax AngularJS vs Angular 5 • Angular 5 start-up – Angular 5 setup – Angular 5 create new project – New project structure – Special Instruction • Angular 5 elements – Components – Interpolation, Property Binding & Event Binding – Route – Services • Angular 5 Deployment
  • 3. INTRODUCTION • Angular is a – JavaScript-based – Open-source – Front-end web application framework – Mainly maintained by Google – And by a community of individuals and corporations – To address many of the challenges encountered in developing single-page applications
  • 5. SOME SYNTAX ANGULARJS VS ANGULAR 5 Syntax AngularJS Angular 5 Model binding ng-model [(ngModel)] Value Binding ng-value [value] Click Binding ng-click (click) Scope creation $scope Not needed Repetition ng-repeat *ngFor
  • 6. ANGULAR 5 START-UP (SETUP) • Open command line interface • Type command to install angular 5 at global level – $ npm install @angular/cli -g • Once the installation is over to check the version of Angular use command – $ ng -v • If you see an output similar to this the installation is over – Angular CLI: 1.6.8 Node: 8.9.1 OS: win32 x64 Angular: …
  • 7. ANGULAR 5 START-UP (CREATE NEW PROJECT) • Open command prompt interface to the folder path • Run the command to generate the angular structure inside the folder: – $ ng new <project_name> –style=scss –routing • Here in above code we are creating a new project with style support for scss and routing enabled • Now get inside the project name folder <project_name> by command – $ cd <project_name> • Now it’s time to run the default project created using command – $ ng serve • Now test your first application by opening the browser and opening url mentioned which running the above command (default http://localhost:4200)
  • 8. ANGULAR 5 START-UP (CREATE NEW PROJECT)
  • 9. ANGULAR 5 START-UP (PROJECT STRUCTURE)
  • 10. ANGULAR 5 START-UP (SPECIAL INSTRUCTION) • To do the changes we will do all our changes inside “src” folder
  • 11. ANGULAR 5 ELEMENTS (COMPONENTS) • Angular components are considered as the basic building blocks of angular app. • Angular components can be found inside “/src/app” folder • Angular components is made up of: – A component decorator, which help to set CSS, animations and many more – Imports needed by the component to work – A Class (here lies the component’s logic)
  • 12. ANGULAR 5 ELEMENTS (COMPONENTS) • Open the cmd in the <project_name> location • Type the command – $ ng generate component <component_name> – You can also do this by using command – $ ng g c <component_name> – Example: • $ ng g c home • The above command will generate the component with other files as: • create src/app/home/home.component.html (23 bytes) create src/app/home/home.component.spec.ts (614 bytes) create src/app/home/home.component.ts (262 bytes) create src/app/home/home.component.scss (0 bytes) update src/app/app.module.ts (467 bytes) • It also maps the new component in the app.module.ts as from above.
  • 13. ANGULAR 5 ELEMENTS (COMPONENTS) • Now if you check the above files let us go through each one by one: – home.component.html : This file contains the html for the home component. All the html changes need to be changed for this component needs to be added in this file. – home.component.ts : This file contains the logic need to be performed for this component under the class “HomeComponent” inside. – home.component.scss : This file contains the CSS styling that needs to be added for the component.
  • 14. ANGULAR 5 ELEMENTS (INTERPOLATION) • When we change some property from the component class to template we use interpolation.
  • 15. ANGULAR 5 ELEMENTS (INTERPOLATION) • Example at: https://abhishekmallickblog.wordpress.com/2018/02/20/ angular-5-interpolation-property-binding-event-binding/
  • 16. ANGULAR 5 ELEMENTS (PROPERTY BINDING) • Binding the properties of the html element with the code in the class
  • 17. ANGULAR 5 ELEMENTS (PROPERTY BINDING) • Example at: https://abhishekmallickblog.wordpress.com/2018/02/20/ angular-5-interpolation-property-binding-event-binding/
  • 18. ANGULAR 5 ELEMENTS (EVENT BINDING) • Say you want to take a data and set data from and to an input box using component class then you use Two- way Binding
  • 19. ANGULAR 5 ELEMENTS (EVENT BINDING) • Example at: https://abhishekmallickblog.wordpress.com/2018/02/20/ angular-5-interpolation-property-binding-event-binding/
  • 20. ANGULAR 5 ELEMENTS (ROUTE) • Route is navigating through the multiple screens of the app.
  • 21. ANGULAR 5 ELEMENTS (ROUTE) • Example at: https://abhishekmallickblog.wordpress.com/2018/02/20/ angular-5-route/
  • 22. ANGULAR 5 ELEMENTS (SERVICES) • Services are class in Angular 5 which are used to provide common features or variables to multiple modules of the app.
  • 23. ANGULAR 5 ELEMENTS (SERVICES) • Example at: https://abhishekmallickblog.wordpress.com/2018/03/25/ angular-5-services/
  • 24. ANGULAR 5 DEPLOYMENT • Normal build – $ ng build – after it executes (might 5 to 15 min) you can see a folder ”/dist” • Production build – $ ng build –prod – after it executes (might 5 to 15 min) you can see a folder ”/dist” • Let us see the difference between both
  • 25. AT LAST OF THEORY • As you can see from the evolution of Angular from 2012 till today, there been multiple iterations. This can help you solve a problem and not the only solution. • So what must be in mind is “These are only tools which can only enable you to solve a problem and only limited what you want to use it for” – Abhishek Mallick
  • 27. THANK YOU FOR BEING SUCH A GREAT FOLKS