Skip to Main Content
Mastering TypeScript 3 - Third Edition
book

Mastering TypeScript 3 - Third Edition

by Nathan Rozentals
February 2019
Beginner content levelBeginner
694 pages
18h 4m
English
Packt Publishing
Content preview from Mastering TypeScript 3 - Third Edition

The BoardList component

Let's start our application updates by creating and integrating a board-list component that will display the list of all boards that are available. This component will query the /api/boards endpoint for data, and will serve as the main page for our site. This BoardListComponent can be created by using the Angular CLI as follows:

ng generate component board-list --skip-import  

This command will generate a /src/app/board-list directory, and also create the .ts, .html, .css, and .spec.ts files for our component. We will need to register this BoardListComponent as a module in the app.module.ts file as follows:

@NgModule({ declarations: [ ... existing components ... BoardListComponent ], imports: [ ... existing code ... ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

The TypeScript Workshop

The TypeScript Workshop

Ben Grynhaus, Jordan Hudgens, Rayon Hunte, Matt Morgan, Wekoslav Stefanovski

Publisher Resources

ISBN: 9781789536706Supplemental Content