Getting Started with Angular: Create and Deploy Angular Applications

Getting Started with Angular: Create and Deploy Angular Applications

Getting Started with Angular: Create and Deploy Angular Applications
Автор: Garcia Victor Hugo
Дата выхода: 2023
Издательство: Apress Media, LLC.
Количество страниц: 410
Размер файла: 4,4 МБ
Тип файла: PDF
Добавил: codelibs
 Проверить на вирусы

Table of Contents....5

About the Author....11

About the Technical Reviewer....12

Introduction....13

978-1-4842-9206-8_1....15

Chapter 1: Introduction to Angular Framework....15

About Angular....15

Semantic Versioning....16

Frequency of Releases....16

Installations Needed....17

NodeJS....17

Google Chrome....17

TypeScript....17

Angular CLI....18

Ionic....19

IDE....19

Postman....24

Errors....25

Summary....25

978-1-4842-9206-8_2....26

Chapter 2: Introduction to TypeScript and ES6....26

Getting Started....26

let and const....27

First File....27

Data Types....37

Boolean....38

Number....38

String....38

Array....39

Any....39

Template Strings....40

Manipulating Strings....40

Functions....43

Arrow Functions....49

Destructuring Objects and Arrays....53

Interfaces....57

Classes....59

What Is a Class?....60

Inheritance....66

Abstract Classes....73

Classes and Interfaces....74

Promises....77

Decorators....83

Summary....85

Questions and Answers....86

Questions....86

Answers....86

978-1-4842-9206-8_3....87

Chapter 3: RestApp Part 1....87

Creating a New Project....87

app.module.ts....93

What We Will Be Building....94

Bootstrap 4....95

Components of Our Application....97

Navbar Component....98

Routing....103

Services....109

An Interface for Users....111

API....111

Summary....135

Untitled....98

Untitled....117

978-1-4842-9206-8_4....136

Chapter 4: RestApp Part 2....136

Bootstrap....136

AboutComponent....140

Forms: ContactComponent....142

Error Handling....146

Update a User....148

Adding a New User....153

Deleting a User....157

Loading....159

Pipes....163

Summary....167

978-1-4842-9206-8_5....168

Chapter 5: AuthApp....168

Auth0....168

Creating an Account....168

Our New App....174

AuthService....175

NavbarComponent....181

Routing....183

Auth0 Settings....186

Local Storage....192

Securing Routes....194

AuthGuard....195

Getting the User’s Profile....204

Exercise....213

Summary....213

978-1-4842-9206-8_6....214

Chapter 6: Blog App Part 1....214

MongoDB....214

What We Will Be Doing....220

Starting the Project....223

Installing Bootstrap....224

Login Component....225

Routes of the Application....228

User Model....229

Login Service....230

Adding the Logic of the Form....231

Application Code....240

Summary....240

978-1-4842-9206-8_7....241

Chapter 7: Blog App Part 2....241

NodeJS....241

Express....241

MongoDB....241

Mongoose....242

Starting the Project on the Server....242

Creating the Database....244

Home Component....252

AuthService: Saving the User in the Session....267

Source Code....272

Summary....272

978-1-4842-9206-8_7 (1)....273

Chapter 7: Blog App Part 2....273

NodeJS....273

Express....273

MongoDB....273

Mongoose....274

Starting the Project on the Server....274

Creating the Database....276

Home Component....284

AuthService: Saving the User in the Session....299

Source Code....304

Summary....304

978-1-4842-9206-8_8....305

Chapter 8: Blog App Part 3: Showing Posts....305

Modifying the User Class....305

Post Component....308

Creating the Post Collection....310

Post Service....315

Post Component....317

Backend Source Code....321

Frontend Source Code....322

Summary....323

978-1-4842-9206-8_9....324

Chapter 9: Blog App Part 4: Filtering Posts....324

Dashboard Component....324

Post Component....331

Filtering Posts....335

Sharpening Details....338

Backend Source Code....339

Frontend Source Code....340

Summary....340

Untitled....338

978-1-4842-9206-8_10....341

Chapter 10: Blog App Part 5: Adding Posts....341

AddPost Component....341

Post Model....348

Observables....355

Backend Source Code....357

Frontend Source Code....358

Summary....358

978-1-4842-9206-8_11....359

Chapter 11: Blog App Part 6: Editing Posts....359

Frontend Post Model....359

Common Service....360

Post Component....362

Dashboard Component....363

AddPost Component....367

AddPost Service....371

updatePost....372

Backend Source Code....373

Frontend Source Code....374

Summary....375

978-1-4842-9206-8_12....376

Chapter 12: Blog App Part 7: Deleting Posts....376

Common Service....376

Dashboard Component....377

Post Component....379

index.js....382

Frontend Source Code....383

Backend Source Code....384

Summary....384

978-1-4842-9206-8_13....385

Chapter 13: Testing....385

Jasmine....385

Karma....386

Testing a Pipe....395

Testing a Service....401

Summary....403

1 (1)....404

Index....404

Immerse yourself in the architecture of an Angular application, starting with an introduction to TypeScript and ES6, and progressing to modules and components used to build complex applications. This book presents a hands-on approach to becoming a proficient Angular developer by building three complete applications.

You’ll start with an overview of the Angular framework where TypeScript and ES6 are introduced. Next you’ll see how to build an application (RestApp) using the in-memory module to mock an API that communicates with a rest API performing crud operations. This is followed by an application (AuthApp) that uses a third party service to provide authentication and authorization capabilities to handle registrations. You’ll then build an application (BlogApp) that communicates with a MongoDB database in six parts.

Part 1 covers MongoDB, how to install bootstrap, login service, and adding the logic of the form. Part 2 covers how to start the project on the server, create the database and AuthService, and save the user in the session. In Parts 3 and 4 you will learn to create the post collection, post component, and sharpen details. In Parts 5 and 6 you will study adding, editing, and deleting posts with testing.

By the end of the book you'll have the necessary knowledge to write and execute automated tests on your applications, and deploy them to a server.

What You’ll Learn

  • Divide the logic of an application into components
  • Communicate with an API
  • Release the power of the observables to solve asynchronous programming problems
  • Include Bootstrap so that your application looks great on different devices

Who This Book Is For

Web developers with basic knowledge of JavaScript, HTML, and CSS.


Похожее:

Список отзывов:

Нет отзывов к книге.