>

CODEMASTERYLAB

IDE PLATFORM
CoursesCommunity BlogsKnowledge GraphQuizzesInterview Prep

Sign in to track progress & earn XP

Sign In Create Account
>
Code Mastery Lab

Code Mastery Lab

Sign In

Passing Data Between Components — Inputs, Outputs, and the Event Contract

Question 1 / 1

0:00
Core
Medium

A RatingComponent has @Output() ratingChanged = new EventEmitter<number>(). The parent template listens with (ratingChanged)="updateRating($event)". Inside RatingComponent, the user clicks a star and calls this.ratingChanged.emit(4). What value does $event hold in the parent's updateRating($event) call, and what type is it?