Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Accelerating Angular Development with Ivy

You're reading from   Accelerating Angular Development with Ivy A practical guide to building faster and more testable Angular apps with the new Ivy engine

Arrow left icon
Product type Paperback
Published in Oct 2021
Publisher Packt
ISBN-13 9781800205215
Length 242 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Authors (3):
Arrow left icon
Lars Gyrup Brink Nielsen Lars Gyrup Brink Nielsen
Author Profile Icon Lars Gyrup Brink Nielsen
Lars Gyrup Brink Nielsen
Jacob Andresen Jacob Andresen
Author Profile Icon Jacob Andresen
Jacob Andresen
Mateus Carniatto Mateus Carniatto
Author Profile Icon Mateus Carniatto
Mateus Carniatto
Arrow right icon
View More author details
Toc

Table of Contents (14) Chapters Close

Preface 1. Chapter 1: Discovering New APIs and Language Syntax 2. Chapter 2: Boosting Developer Productivity Through Tooling, Configuration, and Convenience FREE CHAPTER 3. Chapter 3: Introducing CSS Custom Properties and New Provider Scopes 4. Chapter 4: Exploring Angular Components Features 5. Chapter 5: Using CSS Custom Properties 6. Chapter 6: Using Angular Components 7. Chapter 7: Component Harnesses 8. Chapter 8: Additional Provider Scopes 9. Chapter 9: Debugging with the New Ivy Runtime APIs 10. Chapter 10: Using the Angular Compatibility Compiler 11. Chapter 11: Migrating Your Angular Application from View Engine to Ivy 12. Chapter 12: Embracing Ahead-of-Time Compilation 13. Other Books You May Enjoy

Showing course videos using the Angular YouTube Player

In this section, we'll create a separate video component to display videos that are attached to a course. For simplicity, we'll accept the information as @Input inside the Video component, like so:

 @Component({
  selector: 'workspace-video',
  templateUrl: './video.component.html',
  styleUrls: ['./video.scss'],
})
export class VideoComponent implements OnDestroy, OnInit {
  private youtubeIframeScript: HTMLScriptElement;
  @Input()
  public title!: string;
  @Input()
  public name!: string;
  @Input()
  public videoId!: string;
  @Input()
  public description!: string;
  @Input()
  public snippet!: string;
  get youtubeLink () {
   return this.title 
     + ": https://www.youtube.com/watch?v...
lock icon The rest of the chapter is locked
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 $19.99/month. Cancel anytime