Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Events
Videos
Audiobooks
Packt Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Angular 2 Components

You're reading from   Angular 2 Components Practical and easy-to-follow guide to Angular 2 Components

Arrow left icon
Product type Paperback
Published in Nov 2016
Publisher Packt
ISBN-13 9781785882340
Length 124 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Authors (2):
Arrow left icon
Nir Kaufman Nir Kaufman
Author Profile Icon Nir Kaufman
Nir Kaufman
Thierry Templier Thierry Thierry Templier Thierry
Author Profile Icon Thierry Templier Thierry
Thierry Templier Thierry
Arrow right icon
View More author details
Toc

Table of Contents (11) Chapters Close

Preface 1. Angular 2 Component Architecture FREE CHAPTER 2. Setting Up an Angular 2 Development Environment with angular-cli 3. The TypeScript Primer 4. Building a Basic Component 5. Building Dynamic Components 6. Component Communication 7. Putting It All Together 8. Integrating Third-Party Components 9. Angular 2 Directives Index

The Model-View-Controller pattern

This is an architectural design pattern for implementing user interfaces, which has been used for many years for desktop GUI.

It divides the application into three distinct parts:

  • Model: This is responsible for storing the actual data
  • View: This is the presentation layer that renders the data to the user
  • Controller: The glue between the model and the view

The following diagram describes the relationships between those parts:

The Model-View-Controller pattern

This pattern describes the communication between those parts. The view reflects the data in the model, but cannot alter the data directly in the model. It is common to describe the relationship between the model and the view as read only (the view can only read from the model). The view uses the controller by invoking methods and changing attributes. The controller updates the model, which causes the view to update and render the new data.

MVC, which was originally developed for desktop applications, has been widely adopted as an architecture for building single page web applications and can be found in all the popular client-side frameworks, including Angular.

CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Angular 2 Components
You have been reading a chapter from
Angular 2 Components
Published in: Nov 2016
Publisher: Packt
ISBN-13: 9781785882340
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €18.99/month. Cancel anytime
Modal Close icon
Modal Close icon